1 : <?php
2 : /**
3 : * Smarty Internal Plugin Templateparser
4 : *
5 : * This is the template parser.
6 : * It is generated from the internal.templateparser.y file
7 : * @package Smarty
8 : * @subpackage Compiler
9 : * @author Uwe Tews
10 : */
11 :
12 : /**
13 : * This can be used to store both the string representation of
14 : * a token, and any useful meta-data associated with the token.
15 : *
16 : * meta-data should be stored as an array
17 : */
18 1 : class TP_yyToken implements ArrayAccess
19 : {
20 : public $string = '';
21 : public $metadata = array();
22 :
23 : function __construct($s, $m = array())
24 : {
25 0 : if ($s instanceof TP_yyToken) {
26 0 : $this->string = $s->string;
27 0 : $this->metadata = $s->metadata;
28 0 : } else {
29 0 : $this->string = (string) $s;
30 0 : if ($m instanceof TP_yyToken) {
31 0 : $this->metadata = $m->metadata;
32 0 : } elseif (is_array($m)) {
33 0 : $this->metadata = $m;
34 0 : }
35 : }
36 0 : }
37 :
38 : function __toString()
39 : {
40 0 : return $this->_string;
41 : }
42 :
43 : function offsetExists($offset)
44 : {
45 0 : return isset($this->metadata[$offset]);
46 : }
47 :
48 : function offsetGet($offset)
49 : {
50 0 : return $this->metadata[$offset];
51 : }
52 :
53 : function offsetSet($offset, $value)
54 : {
55 0 : if ($offset === null) {
56 0 : if (isset($value[0])) {
57 0 : $x = ($value instanceof TP_yyToken) ?
58 0 : $value->metadata : $value;
59 0 : $this->metadata = array_merge($this->metadata, $x);
60 0 : return;
61 : }
62 0 : $offset = count($this->metadata);
63 0 : }
64 0 : if ($value === null) {
65 0 : return;
66 : }
67 0 : if ($value instanceof TP_yyToken) {
68 0 : if ($value->metadata) {
69 0 : $this->metadata[$offset] = $value->metadata;
70 0 : }
71 0 : } elseif ($value) {
72 0 : $this->metadata[$offset] = $value;
73 0 : }
74 0 : }
75 :
76 : function offsetUnset($offset)
77 : {
78 0 : unset($this->metadata[$offset]);
79 0 : }
80 : }
81 :
82 : /** The following structure represents a single element of the
83 : * parser's stack. Information stored includes:
84 : *
85 : * + The state number for the parser at this level of the stack.
86 : *
87 : * + The value of the token stored at this level of the stack.
88 : * (In other words, the "major" token.)
89 : *
90 : * + The semantic value stored at this level of the stack. This is
91 : * the information used by the action routines in the grammar.
92 : * It is sometimes called the "minor" token.
93 : */
94 : class TP_yyStackEntry
95 1 : {
96 : public $stateno; /* The state-number */
97 : public $major; /* The major token value. This is the code
98 : ** number for the token at this stack level */
99 : public $minor; /* The user-supplied minor token value. This
100 : ** is the value of the token */
101 : };
102 :
103 : // code external to the class is included here
104 :
105 : // declare_class is output here
106 : #line 12 "internal.templateparser.y"
107 : class Smarty_Internal_Templateparser#line 109 "internal.templateparser.php"
108 1 : {
109 : /* First off, code is included which follows the "include_class" declaration
110 : ** in the input file. */
111 : #line 14 "internal.templateparser.y"
112 :
113 : // states whether the parse was successful or not
114 : public $successful = true;
115 : public $retvalue = 0;
116 : private $lex;
117 : private $internalError = false;
118 :
119 : function __construct($lex, $compiler) {
120 : // set instance object
121 278 : self::instance($this);
122 278 : $this->lex = $lex;
123 278 : $this->smarty = Smarty::instance();
124 278 : $this->compiler = $compiler;
125 278 : $this->template = $this->compiler->template;
126 278 : $this->cacher = $this->template->cacher_object;
127 278 : $this->nocache = false;
128 278 : $this->prefix_code = array();
129 278 : $this->prefix_number = 0;
130 278 : }
131 : public static function &instance($new_instance = null)
132 : {
133 278 : static $instance = null;
134 278 : if (isset($new_instance) && is_object($new_instance))
135 278 : $instance = $new_instance;
136 278 : return $instance;
137 : }
138 :
139 : #line 142 "internal.templateparser.php"
140 :
141 : /* Next is all token values, as class constants
142 : */
143 : /*
144 : ** These constants (all generated automatically by the parser generator)
145 : ** specify the various kinds of tokens (terminals) that the parser
146 : ** understands.
147 : **
148 : ** Each symbol here is a terminal symbol in the grammar.
149 : */
150 : const TP_OTHER = 1;
151 : const TP_LDELSLASH = 2;
152 : const TP_LDEL = 3;
153 : const TP_RDEL = 4;
154 : const TP_XML = 5;
155 : const TP_PHP = 6;
156 : const TP_SHORTTAGSTART = 7;
157 : const TP_SHORTTAGEND = 8;
158 : const TP_COMMENTEND = 9;
159 : const TP_COMMENTSTART = 10;
160 : const TP_NUMBER = 11;
161 : const TP_MATH = 12;
162 : const TP_UNIMATH = 13;
163 : const TP_INCDEC = 14;
164 : const TP_OPENP = 15;
165 : const TP_CLOSEP = 16;
166 : const TP_OPENB = 17;
167 : const TP_CLOSEB = 18;
168 : const TP_DOLLAR = 19;
169 : const TP_DOT = 20;
170 : const TP_COMMA = 21;
171 : const TP_COLON = 22;
172 : const TP_DOUBLECOLON = 23;
173 : const TP_SEMICOLON = 24;
174 : const TP_VERT = 25;
175 : const TP_EQUAL = 26;
176 : const TP_SPACE = 27;
177 : const TP_PTR = 28;
178 : const TP_APTR = 29;
179 : const TP_ID = 30;
180 : const TP_EQUALS = 31;
181 : const TP_NOTEQUALS = 32;
182 : const TP_GREATERTHAN = 33;
183 : const TP_LESSTHAN = 34;
184 : const TP_GREATEREQUAL = 35;
185 : const TP_LESSEQUAL = 36;
186 : const TP_IDENTITY = 37;
187 : const TP_NONEIDENTITY = 38;
188 : const TP_NOT = 39;
189 : const TP_LAND = 40;
190 : const TP_LOR = 41;
191 : const TP_QUOTE = 42;
192 : const TP_SINGLEQUOTE = 43;
193 : const TP_BOOLEAN = 44;
194 : const TP_NULL = 45;
195 : const TP_IN = 46;
196 : const TP_ANDSYM = 47;
197 : const TP_BACKTICK = 48;
198 : const TP_HATCH = 49;
199 : const TP_AT = 50;
200 : const TP_ISODD = 51;
201 : const TP_ISNOTODD = 52;
202 : const TP_ISEVEN = 53;
203 : const TP_ISNOTEVEN = 54;
204 : const TP_ISODDBY = 55;
205 : const TP_ISNOTODDBY = 56;
206 : const TP_ISEVENBY = 57;
207 : const TP_ISNOTEVENBY = 58;
208 : const TP_ISDIVBY = 59;
209 : const TP_ISNOTDIVBY = 60;
210 : const TP_LITERALSTART = 61;
211 : const TP_LITERALEND = 62;
212 : const TP_LDELIMTAG = 63;
213 : const TP_RDELIMTAG = 64;
214 : const TP_PHPSTART = 65;
215 : const TP_PHPEND = 66;
216 : const YY_NO_ACTION = 373;
217 : const YY_ACCEPT_ACTION = 372;
218 : const YY_ERROR_ACTION = 371;
219 :
220 : /* Next are that tables used to determine what action to take based on the
221 : ** current state and lookahead token. These tables are used to implement
222 : ** functions that take a state number and lookahead value and return an
223 : ** action integer.
224 : **
225 : ** Suppose the action integer is N. Then the action is determined as
226 : ** follows
227 : **
228 : ** 0 <= N < self::YYNSTATE Shift N. That is,
229 : ** push the lookahead
230 : ** token onto the stack
231 : ** and goto state N.
232 : **
233 : ** self::YYNSTATE <= N < self::YYNSTATE+self::YYNRULE Reduce by rule N-YYNSTATE.
234 : **
235 : ** N == self::YYNSTATE+self::YYNRULE A syntax error has occurred.
236 : **
237 : ** N == self::YYNSTATE+self::YYNRULE+1 The parser accepts its
238 : ** input. (and concludes parsing)
239 : **
240 : ** N == self::YYNSTATE+self::YYNRULE+2 No such action. Denotes unused
241 : ** slots in the yy_action[] table.
242 : **
243 : ** The action table is constructed as a single large static array $yy_action.
244 : ** Given state S and lookahead X, the action is computed as
245 : **
246 : ** self::$yy_action[self::$yy_shift_ofst[S] + X ]
247 : **
248 : ** If the index value self::$yy_shift_ofst[S]+X is out of range or if the value
249 : ** self::$yy_lookahead[self::$yy_shift_ofst[S]+X] is not equal to X or if
250 : ** self::$yy_shift_ofst[S] is equal to self::YY_SHIFT_USE_DFLT, it means that
251 : ** the action is not in the table and that self::$yy_default[S] should be used instead.
252 : **
253 : ** The formula above is for computing the action when the lookahead is
254 : ** a terminal symbol. If the lookahead is a non-terminal (as occurs after
255 : ** a reduce action) then the static $yy_reduce_ofst array is used in place of
256 : ** the static $yy_shift_ofst array and self::YY_REDUCE_USE_DFLT is used in place of
257 : ** self::YY_SHIFT_USE_DFLT.
258 : **
259 : ** The following are the tables generated in this section:
260 : **
261 : ** self::$yy_action A single table containing all actions.
262 : ** self::$yy_lookahead A table containing the lookahead for each entry in
263 : ** yy_action. Used to detect hash collisions.
264 : ** self::$yy_shift_ofst For each state, the offset into self::$yy_action for
265 : ** shifting terminals.
266 : ** self::$yy_reduce_ofst For each state, the offset into self::$yy_action for
267 : ** shifting non-terminals after a reduce.
268 : ** self::$yy_default Default action for each state.
269 : */
270 : const YY_SZ_ACTTAB = 794;
271 : static public $yy_action = array(
272 : /* 0 */ 129, 236, 195, 141, 18, 120, 196, 168, 61, 26,
273 : /* 10 */ 16, 52, 120, 163, 120, 167, 145, 146, 225, 224,
274 : /* 20 */ 216, 184, 214, 212, 213, 217, 186, 157, 160, 166,
275 : /* 30 */ 153, 3, 4, 5, 2, 11, 10, 145, 146, 60,
276 : /* 40 */ 99, 230, 228, 174, 149, 204, 131, 203, 157, 160,
277 : /* 50 */ 166, 153, 3, 4, 5, 2, 11, 10, 372, 42,
278 : /* 60 */ 155, 177, 56, 88, 170, 171, 58, 101, 145, 146,
279 : /* 70 */ 174, 163, 204, 167, 100, 199, 32, 9, 165, 157,
280 : /* 80 */ 160, 166, 153, 3, 4, 5, 2, 11, 10, 145,
281 : /* 90 */ 146, 151, 109, 33, 23, 8, 163, 12, 167, 53,
282 : /* 100 */ 157, 160, 166, 153, 3, 4, 5, 2, 11, 10,
283 : /* 110 */ 117, 154, 151, 219, 33, 140, 8, 24, 12, 6,
284 : /* 120 */ 55, 185, 35, 49, 159, 156, 139, 190, 151, 126,
285 : /* 130 */ 33, 114, 21, 205, 12, 19, 53, 31, 221, 189,
286 : /* 140 */ 6, 137, 15, 35, 49, 159, 156, 117, 120, 23,
287 : /* 150 */ 126, 53, 163, 28, 167, 125, 30, 147, 44, 35,
288 : /* 160 */ 49, 159, 156, 70, 110, 23, 126, 183, 175, 187,
289 : /* 170 */ 80, 151, 152, 33, 201, 21, 185, 12, 218, 53,
290 : /* 180 */ 59, 23, 205, 222, 19, 17, 147, 151, 24, 33,
291 : /* 190 */ 118, 21, 185, 12, 192, 53, 183, 175, 200, 76,
292 : /* 200 */ 53, 152, 35, 49, 159, 156, 115, 218, 185, 126,
293 : /* 210 */ 234, 79, 137, 169, 231, 29, 23, 123, 35, 49,
294 : /* 220 */ 159, 156, 41, 223, 23, 126, 37, 173, 137, 59,
295 : /* 230 */ 151, 218, 33, 197, 21, 104, 12, 123, 53, 25,
296 : /* 240 */ 204, 215, 120, 185, 176, 147, 151, 24, 33, 116,
297 : /* 250 */ 21, 185, 12, 209, 53, 183, 175, 78, 83, 14,
298 : /* 260 */ 152, 35, 49, 159, 156, 113, 218, 86, 126, 123,
299 : /* 270 */ 134, 234, 227, 22, 120, 93, 147, 35, 49, 159,
300 : /* 280 */ 156, 230, 228, 29, 126, 210, 183, 175, 123, 75,
301 : /* 290 */ 176, 152, 218, 147, 44, 123, 179, 218, 226, 64,
302 : /* 300 */ 122, 120, 233, 183, 175, 151, 80, 33, 152, 21,
303 : /* 310 */ 14, 12, 237, 57, 218, 82, 32, 110, 86, 222,
304 : /* 320 */ 120, 151, 1, 130, 36, 21, 132, 12, 229, 53,
305 : /* 330 */ 191, 90, 94, 111, 112, 47, 35, 49, 159, 156,
306 : /* 340 */ 121, 210, 210, 126, 112, 28, 150, 218, 30, 14,
307 : /* 350 */ 191, 123, 35, 49, 159, 156, 197, 86, 14, 126,
308 : /* 360 */ 163, 202, 167, 148, 177, 120, 86, 20, 162, 123,
309 : /* 370 */ 108, 225, 224, 216, 184, 214, 212, 213, 217, 147,
310 : /* 380 */ 44, 147, 120, 226, 123, 69, 163, 89, 167, 183,
311 : /* 390 */ 175, 232, 80, 81, 152, 14, 152, 210, 147, 44,
312 : /* 400 */ 218, 48, 218, 86, 68, 222, 27, 46, 183, 175,
313 : /* 410 */ 147, 80, 38, 152, 45, 187, 191, 147, 44, 218,
314 : /* 420 */ 135, 136, 191, 74, 222, 152, 176, 183, 175, 191,
315 : /* 430 */ 80, 218, 152, 112, 128, 51, 63, 107, 218, 147,
316 : /* 440 */ 44, 235, 204, 222, 77, 72, 147, 87, 161, 183,
317 : /* 450 */ 175, 127, 80, 7, 152, 218, 183, 175, 92, 80,
318 : /* 460 */ 218, 152, 133, 147, 43, 222, 194, 218, 210, 65,
319 : /* 470 */ 147, 181, 208, 183, 175, 182, 80, 176, 152, 97,
320 : /* 480 */ 158, 188, 147, 44, 218, 152, 151, 180, 71, 222,
321 : /* 490 */ 21, 218, 183, 175, 53, 80, 144, 152, 27, 172,
322 : /* 500 */ 211, 147, 85, 218, 50, 121, 178, 53, 222, 34,
323 : /* 510 */ 62, 183, 175, 147, 80, 187, 152, 35, 49, 159,
324 : /* 520 */ 156, 13, 218, 220, 126, 123, 147, 44, 152, 193,
325 : /* 530 */ 119, 206, 73, 164, 218, 54, 183, 175, 39, 80,
326 : /* 540 */ 241, 152, 174, 147, 44, 241, 241, 218, 241, 67,
327 : /* 550 */ 241, 241, 222, 183, 175, 241, 80, 241, 152, 241,
328 : /* 560 */ 147, 44, 241, 241, 218, 241, 66, 147, 91, 222,
329 : /* 570 */ 183, 175, 241, 80, 241, 152, 241, 183, 175, 241,
330 : /* 580 */ 80, 218, 152, 241, 241, 207, 222, 241, 218, 241,
331 : /* 590 */ 147, 91, 241, 241, 241, 241, 241, 241, 241, 241,
332 : /* 600 */ 183, 175, 241, 80, 241, 152, 147, 91, 142, 241,
333 : /* 610 */ 241, 218, 241, 241, 241, 241, 183, 175, 241, 80,
334 : /* 620 */ 241, 152, 241, 241, 138, 241, 241, 218, 147, 85,
335 : /* 630 */ 241, 241, 241, 241, 241, 147, 91, 241, 183, 175,
336 : /* 640 */ 241, 80, 241, 152, 241, 183, 175, 241, 80, 218,
337 : /* 650 */ 152, 147, 40, 143, 124, 241, 218, 241, 198, 241,
338 : /* 660 */ 241, 183, 175, 241, 80, 241, 152, 241, 241, 241,
339 : /* 670 */ 241, 241, 218, 241, 147, 98, 241, 241, 241, 241,
340 : /* 680 */ 241, 147, 106, 241, 183, 175, 241, 80, 241, 152,
341 : /* 690 */ 241, 183, 175, 241, 80, 218, 152, 241, 147, 95,
342 : /* 700 */ 241, 241, 218, 241, 241, 241, 241, 241, 183, 175,
343 : /* 710 */ 241, 80, 241, 152, 241, 147, 105, 241, 241, 218,
344 : /* 720 */ 241, 241, 147, 84, 241, 183, 175, 241, 80, 241,
345 : /* 730 */ 152, 241, 183, 175, 241, 80, 218, 152, 147, 96,
346 : /* 740 */ 241, 241, 241, 218, 241, 241, 241, 241, 183, 175,
347 : /* 750 */ 241, 80, 241, 152, 241, 147, 103, 241, 241, 218,
348 : /* 760 */ 241, 241, 241, 241, 241, 183, 175, 241, 80, 241,
349 : /* 770 */ 152, 241, 147, 102, 241, 241, 218, 241, 241, 241,
350 : /* 780 */ 241, 241, 183, 175, 241, 80, 241, 152, 241, 241,
351 : /* 790 */ 241, 241, 241, 218,
352 : );
353 : static public $yy_lookahead = array(
354 : /* 0 */ 24, 4, 1, 2, 3, 25, 5, 6, 7, 29,
355 : /* 10 */ 21, 10, 25, 1, 25, 3, 40, 41, 31, 32,
356 : /* 20 */ 33, 34, 35, 36, 37, 38, 30, 51, 52, 53,
357 : /* 30 */ 54, 55, 56, 57, 58, 59, 60, 40, 41, 16,
358 : /* 40 */ 92, 12, 13, 95, 16, 97, 50, 18, 51, 52,
359 : /* 50 */ 53, 54, 55, 56, 57, 58, 59, 60, 68, 69,
360 : /* 60 */ 70, 71, 61, 93, 63, 64, 65, 92, 40, 41,
361 : /* 70 */ 95, 1, 97, 3, 21, 16, 47, 24, 66, 51,
362 : /* 80 */ 52, 53, 54, 55, 56, 57, 58, 59, 60, 40,
363 : /* 90 */ 41, 11, 30, 13, 3, 15, 1, 17, 3, 19,
364 : /* 100 */ 51, 52, 53, 54, 55, 56, 57, 58, 59, 60,
365 : /* 110 */ 30, 4, 11, 43, 13, 19, 15, 26, 17, 39,
366 : /* 120 */ 19, 30, 42, 43, 44, 45, 30, 4, 11, 49,
367 : /* 130 */ 13, 30, 15, 1, 17, 3, 19, 46, 43, 18,
368 : /* 140 */ 39, 50, 21, 42, 43, 44, 45, 30, 25, 3,
369 : /* 150 */ 49, 19, 1, 17, 3, 82, 20, 73, 74, 42,
370 : /* 160 */ 43, 44, 45, 79, 28, 3, 49, 83, 84, 96,
371 : /* 170 */ 86, 11, 88, 13, 42, 15, 30, 17, 94, 19,
372 : /* 180 */ 48, 3, 1, 99, 3, 15, 73, 11, 26, 13,
373 : /* 190 */ 30, 15, 30, 17, 4, 19, 83, 84, 90, 86,
374 : /* 200 */ 19, 88, 42, 43, 44, 45, 30, 94, 30, 49,
375 : /* 210 */ 73, 72, 50, 62, 4, 22, 3, 27, 42, 43,
376 : /* 220 */ 44, 45, 78, 42, 3, 49, 89, 14, 50, 48,
377 : /* 230 */ 11, 94, 13, 16, 15, 92, 17, 27, 19, 26,
378 : /* 240 */ 97, 104, 25, 30, 105, 73, 11, 26, 13, 30,
379 : /* 250 */ 15, 30, 17, 4, 19, 83, 84, 72, 86, 15,
380 : /* 260 */ 88, 42, 43, 44, 45, 30, 94, 23, 49, 27,
381 : /* 270 */ 28, 73, 4, 29, 25, 75, 73, 42, 43, 44,
382 : /* 280 */ 45, 12, 13, 22, 49, 85, 83, 84, 27, 86,
383 : /* 290 */ 105, 88, 94, 73, 74, 27, 76, 94, 98, 79,
384 : /* 300 */ 80, 25, 104, 83, 84, 11, 86, 13, 88, 15,
385 : /* 310 */ 15, 17, 97, 19, 94, 81, 47, 28, 23, 99,
386 : /* 320 */ 25, 11, 27, 28, 30, 15, 73, 17, 4, 19,
387 : /* 330 */ 96, 75, 75, 77, 77, 81, 42, 43, 44, 45,
388 : /* 340 */ 30, 85, 85, 49, 77, 17, 4, 94, 20, 15,
389 : /* 350 */ 96, 27, 42, 43, 44, 45, 16, 23, 15, 49,
390 : /* 360 */ 1, 18, 3, 70, 71, 25, 23, 100, 9, 27,
391 : /* 370 */ 78, 31, 32, 33, 34, 35, 36, 37, 38, 73,
392 : /* 380 */ 74, 73, 25, 98, 27, 79, 1, 75, 3, 83,
393 : /* 390 */ 84, 83, 86, 72, 88, 15, 88, 85, 73, 74,
394 : /* 400 */ 94, 81, 94, 23, 79, 99, 26, 81, 83, 84,
395 : /* 410 */ 73, 86, 93, 88, 81, 96, 96, 73, 74, 94,
396 : /* 420 */ 83, 84, 96, 79, 99, 88, 105, 83, 84, 96,
397 : /* 430 */ 86, 94, 88, 77, 73, 19, 30, 92, 94, 73,
398 : /* 440 */ 74, 48, 97, 99, 72, 79, 73, 74, 49, 83,
399 : /* 450 */ 84, 30, 86, 101, 88, 94, 83, 84, 75, 86,
400 : /* 460 */ 94, 88, 30, 73, 74, 99, 30, 94, 85, 79,
401 : /* 470 */ 73, 8, 16, 83, 84, 4, 86, 105, 88, 30,
402 : /* 480 */ 83, 30, 73, 74, 94, 88, 11, 4, 79, 99,
403 : /* 490 */ 15, 94, 83, 84, 19, 86, 30, 88, 26, 4,
404 : /* 500 */ 4, 73, 74, 94, 30, 30, 105, 19, 99, 87,
405 : /* 510 */ 90, 83, 84, 73, 86, 96, 88, 42, 43, 44,
406 : /* 520 */ 45, 15, 94, 83, 49, 27, 73, 74, 88, 85,
407 : /* 530 */ 102, 103, 79, 76, 94, 19, 83, 84, 93, 86,
408 : /* 540 */ 106, 88, 95, 73, 74, 106, 106, 94, 106, 79,
409 : /* 550 */ 106, 106, 99, 83, 84, 106, 86, 106, 88, 106,
410 : /* 560 */ 73, 74, 106, 106, 94, 106, 79, 73, 74, 99,
411 : /* 570 */ 83, 84, 106, 86, 106, 88, 106, 83, 84, 106,
412 : /* 580 */ 86, 94, 88, 106, 106, 91, 99, 106, 94, 106,
413 : /* 590 */ 73, 74, 106, 106, 106, 106, 106, 106, 106, 106,
414 : /* 600 */ 83, 84, 106, 86, 106, 88, 73, 74, 91, 106,
415 : /* 610 */ 106, 94, 106, 106, 106, 106, 83, 84, 106, 86,
416 : /* 620 */ 106, 88, 106, 106, 91, 106, 106, 94, 73, 74,
417 : /* 630 */ 106, 106, 106, 106, 106, 73, 74, 106, 83, 84,
418 : /* 640 */ 106, 86, 106, 88, 106, 83, 84, 106, 86, 94,
419 : /* 650 */ 88, 73, 74, 91, 76, 106, 94, 106, 103, 106,
420 : /* 660 */ 106, 83, 84, 106, 86, 106, 88, 106, 106, 106,
421 : /* 670 */ 106, 106, 94, 106, 73, 74, 106, 106, 106, 106,
422 : /* 680 */ 106, 73, 74, 106, 83, 84, 106, 86, 106, 88,
423 : /* 690 */ 106, 83, 84, 106, 86, 94, 88, 106, 73, 74,
424 : /* 700 */ 106, 106, 94, 106, 106, 106, 106, 106, 83, 84,
425 : /* 710 */ 106, 86, 106, 88, 106, 73, 74, 106, 106, 94,
426 : /* 720 */ 106, 106, 73, 74, 106, 83, 84, 106, 86, 106,
427 : /* 730 */ 88, 106, 83, 84, 106, 86, 94, 88, 73, 74,
428 : /* 740 */ 106, 106, 106, 94, 106, 106, 106, 106, 83, 84,
429 : /* 750 */ 106, 86, 106, 88, 106, 73, 74, 106, 106, 94,
430 : /* 760 */ 106, 106, 106, 106, 106, 83, 84, 106, 86, 106,
431 : /* 770 */ 88, 106, 73, 74, 106, 106, 94, 106, 106, 106,
432 : /* 780 */ 106, 106, 83, 84, 106, 86, 106, 88, 106, 106,
433 : /* 790 */ 106, 106, 106, 94,
434 : );
435 : const YY_SHIFT_USE_DFLT = -25;
436 : const YY_SHIFT_MAX = 144;
437 : static public $yy_shift_ofst = array(
438 : /* 0 */ 1, 101, 80, 80, 80, 80, 80, 80, 80, 80,
439 : /* 10 */ 80, 80, 235, 117, 117, 235, 117, 117, 294, 117,
440 : /* 20 */ 117, 117, 117, 117, 117, 117, 117, 117, 176, 219,
441 : /* 30 */ 160, 310, 475, 475, 475, 132, 295, 181, 136, 136,
442 : /* 40 */ 357, 261, 1, 340, -13, 91, 213, 162, 178, 95,
443 : /* 50 */ 242, 146, 385, 146, 146, 146, 385, 146, 385, 488,
444 : /* 60 */ 289, 488, 289, 498, -3, 28, -24, 49, 49, 49,
445 : /* 70 */ 49, 49, 49, 49, 49, 29, 269, 12, 70, 151,
446 : /* 80 */ 269, 359, 221, 269, 249, -20, 96, 217, 328, 342,
447 : /* 90 */ 324, -11, 268, 210, 190, 123, 276, 506, 276, 289,
448 : /* 100 */ 516, 289, 276, 276, 289, 276, 276, 289, 193, 170,
449 : /* 110 */ 62, -25, -25, 244, 380, 343, 334, 334, 334, 121,
450 : /* 120 */ -4, 334, 53, 432, 496, 471, 421, 399, 393, 416,
451 : /* 130 */ 406, 436, 463, 472, 466, 495, 483, 451, 456, 170,
452 : /* 140 */ 449, 474, 23, 59, 107,
453 : );
454 : const YY_REDUCE_USE_DFLT = -53;
455 : const YY_REDUCE_MAX = 112;
456 : static public $yy_reduce_ofst = array(
457 : /* 0 */ -10, 220, 366, 344, 409, 325, 306, 84, 390, 487,
458 : /* 10 */ 453, 470, 428, 517, 533, 555, 494, 562, 578, 649,
459 : /* 20 */ 665, 373, 642, 625, 601, 699, 608, 682, 203, 172,
460 : /* 30 */ 113, 337, 308, 397, 440, 137, 256, 198, -25, -52,
461 : /* 40 */ 257, 200, 293, 267, 267, 319, 73, 319, 319, 185,
462 : /* 50 */ 312, 326, 321, 320, 234, 333, 139, 254, 372, 361,
463 : /* 60 */ 143, 253, 345, 383, 352, 352, 352, 352, 352, 352,
464 : /* 70 */ 352, 352, 352, 352, 352, 422, 422, 401, 401, 401,
465 : /* 80 */ 422, 401, 419, 422, 356, 356, 420, 356, 447, 444,
466 : /* 90 */ 444, 356, 444, 444, 444, 356, 356, 445, 356, 215,
467 : /* 100 */ 457, 215, 356, 356, 215, 356, 356, 215, 285, -30,
468 : /* 110 */ 108, 144, 292,
469 : );
470 : static public $yyExpectedTokens = array(
471 : /* 0 */ array(1, 2, 3, 5, 6, 7, 10, 61, 63, 64, 65, ),
472 : /* 1 */ array(11, 13, 15, 17, 19, 30, 39, 42, 43, 44, 45, 49, ),
473 : /* 2 */ array(11, 13, 15, 17, 19, 30, 39, 42, 43, 44, 45, 49, ),
474 : /* 3 */ array(11, 13, 15, 17, 19, 30, 39, 42, 43, 44, 45, 49, ),
475 : /* 4 */ array(11, 13, 15, 17, 19, 30, 39, 42, 43, 44, 45, 49, ),
476 : /* 5 */ array(11, 13, 15, 17, 19, 30, 39, 42, 43, 44, 45, 49, ),
477 : /* 6 */ array(11, 13, 15, 17, 19, 30, 39, 42, 43, 44, 45, 49, ),
478 : /* 7 */ array(11, 13, 15, 17, 19, 30, 39, 42, 43, 44, 45, 49, ),
479 : /* 8 */ array(11, 13, 15, 17, 19, 30, 39, 42, 43, 44, 45, 49, ),
480 : /* 9 */ array(11, 13, 15, 17, 19, 30, 39, 42, 43, 44, 45, 49, ),
481 : /* 10 */ array(11, 13, 15, 17, 19, 30, 39, 42, 43, 44, 45, 49, ),
482 : /* 11 */ array(11, 13, 15, 17, 19, 30, 39, 42, 43, 44, 45, 49, ),
483 : /* 12 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
484 : /* 13 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
485 : /* 14 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
486 : /* 15 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
487 : /* 16 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
488 : /* 17 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
489 : /* 18 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
490 : /* 19 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
491 : /* 20 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
492 : /* 21 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
493 : /* 22 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
494 : /* 23 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
495 : /* 24 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
496 : /* 25 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
497 : /* 26 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
498 : /* 27 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
499 : /* 28 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
500 : /* 29 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
501 : /* 30 */ array(11, 13, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
502 : /* 31 */ array(11, 15, 17, 19, 30, 42, 43, 44, 45, 49, ),
503 : /* 32 */ array(11, 15, 19, 30, 42, 43, 44, 45, 49, ),
504 : /* 33 */ array(11, 15, 19, 30, 42, 43, 44, 45, 49, ),
505 : /* 34 */ array(11, 15, 19, 30, 42, 43, 44, 45, 49, ),
506 : /* 35 */ array(1, 3, 19, 42, 48, ),
507 : /* 36 */ array(15, 23, 25, 27, 28, ),
508 : /* 37 */ array(1, 3, 19, 42, 48, ),
509 : /* 38 */ array(17, 20, 28, ),
510 : /* 39 */ array(17, 20, 28, ),
511 : /* 40 */ array(25, 27, ),
512 : /* 41 */ array(22, 27, ),
513 : /* 42 */ array(1, 2, 3, 5, 6, 7, 10, 61, 63, 64, 65, ),
514 : /* 43 */ array(16, 25, 31, 32, 33, 34, 35, 36, 37, 38, ),
515 : /* 44 */ array(25, 31, 32, 33, 34, 35, 36, 37, 38, ),
516 : /* 45 */ array(3, 26, 30, 46, 50, ),
517 : /* 46 */ array(3, 14, 26, 30, ),
518 : /* 47 */ array(3, 26, 30, 50, ),
519 : /* 48 */ array(3, 30, 50, ),
520 : /* 49 */ array(1, 3, 43, ),
521 : /* 50 */ array(27, 28, ),
522 : /* 51 */ array(3, 30, ),
523 : /* 52 */ array(1, 3, ),
524 : /* 53 */ array(3, 30, ),
525 : /* 54 */ array(3, 30, ),
526 : /* 55 */ array(3, 30, ),
527 : /* 56 */ array(1, 3, ),
528 : /* 57 */ array(3, 30, ),
529 : /* 58 */ array(1, 3, ),
530 : /* 59 */ array(19, ),
531 : /* 60 */ array(28, ),
532 : /* 61 */ array(19, ),
533 : /* 62 */ array(28, ),
534 : /* 63 */ array(27, ),
535 : /* 64 */ array(4, 40, 41, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, ),
536 : /* 65 */ array(16, 40, 41, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, ),
537 : /* 66 */ array(24, 40, 41, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, ),
538 : /* 67 */ array(40, 41, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, ),
539 : /* 68 */ array(40, 41, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, ),
540 : /* 69 */ array(40, 41, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, ),
541 : /* 70 */ array(40, 41, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, ),
542 : /* 71 */ array(40, 41, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, ),
543 : /* 72 */ array(40, 41, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, ),
544 : /* 73 */ array(40, 41, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, ),
545 : /* 74 */ array(40, 41, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, ),
546 : /* 75 */ array(12, 13, 18, 47, ),
547 : /* 76 */ array(12, 13, 47, ),
548 : /* 77 */ array(1, 3, 66, ),
549 : /* 78 */ array(1, 3, 43, ),
550 : /* 79 */ array(1, 3, 62, ),
551 : /* 80 */ array(12, 13, 47, ),
552 : /* 81 */ array(1, 3, 9, ),
553 : /* 82 */ array(3, 26, 30, ),
554 : /* 83 */ array(12, 13, 47, ),
555 : /* 84 */ array(4, 25, ),
556 : /* 85 */ array(25, 29, ),
557 : /* 86 */ array(19, 30, ),
558 : /* 87 */ array(16, 25, ),
559 : /* 88 */ array(17, 20, ),
560 : /* 89 */ array(4, 27, ),
561 : /* 90 */ array(4, 27, ),
562 : /* 91 */ array(21, 25, ),
563 : /* 92 */ array(4, 27, ),
564 : /* 93 */ array(4, 27, ),
565 : /* 94 */ array(4, 27, ),
566 : /* 95 */ array(4, 25, ),
567 : /* 96 */ array(25, ),
568 : /* 97 */ array(15, ),
569 : /* 98 */ array(25, ),
570 : /* 99 */ array(28, ),
571 : /* 100 */ array(19, ),
572 : /* 101 */ array(28, ),
573 : /* 102 */ array(25, ),
574 : /* 103 */ array(25, ),
575 : /* 104 */ array(28, ),
576 : /* 105 */ array(25, ),
577 : /* 106 */ array(25, ),
578 : /* 107 */ array(28, ),
579 : /* 108 */ array(22, ),
580 : /* 109 */ array(15, ),
581 : /* 110 */ array(30, ),
582 : /* 111 */ array(),
583 : /* 112 */ array(),
584 : /* 113 */ array(15, 23, 29, ),
585 : /* 114 */ array(15, 23, 26, ),
586 : /* 115 */ array(15, 18, 23, ),
587 : /* 116 */ array(15, 23, ),
588 : /* 117 */ array(15, 23, ),
589 : /* 118 */ array(15, 23, ),
590 : /* 119 */ array(18, 21, ),
591 : /* 120 */ array(30, 50, ),
592 : /* 121 */ array(15, 23, ),
593 : /* 122 */ array(21, 24, ),
594 : /* 123 */ array(30, ),
595 : /* 124 */ array(4, ),
596 : /* 125 */ array(4, ),
597 : /* 126 */ array(30, ),
598 : /* 127 */ array(49, ),
599 : /* 128 */ array(48, ),
600 : /* 129 */ array(19, ),
601 : /* 130 */ array(30, ),
602 : /* 131 */ array(30, ),
603 : /* 132 */ array(8, ),
604 : /* 133 */ array(26, ),
605 : /* 134 */ array(30, ),
606 : /* 135 */ array(4, ),
607 : /* 136 */ array(4, ),
608 : /* 137 */ array(30, ),
609 : /* 138 */ array(16, ),
610 : /* 139 */ array(15, ),
611 : /* 140 */ array(30, ),
612 : /* 141 */ array(30, ),
613 : /* 142 */ array(16, ),
614 : /* 143 */ array(16, ),
615 : /* 144 */ array(4, ),
616 : /* 145 */ array(),
617 : /* 146 */ array(),
618 : /* 147 */ array(),
619 : /* 148 */ array(),
620 : /* 149 */ array(),
621 : /* 150 */ array(),
622 : /* 151 */ array(),
623 : /* 152 */ array(),
624 : /* 153 */ array(),
625 : /* 154 */ array(),
626 : /* 155 */ array(),
627 : /* 156 */ array(),
628 : /* 157 */ array(),
629 : /* 158 */ array(),
630 : /* 159 */ array(),
631 : /* 160 */ array(),
632 : /* 161 */ array(),
633 : /* 162 */ array(),
634 : /* 163 */ array(),
635 : /* 164 */ array(),
636 : /* 165 */ array(),
637 : /* 166 */ array(),
638 : /* 167 */ array(),
639 : /* 168 */ array(),
640 : /* 169 */ array(),
641 : /* 170 */ array(),
642 : /* 171 */ array(),
643 : /* 172 */ array(),
644 : /* 173 */ array(),
645 : /* 174 */ array(),
646 : /* 175 */ array(),
647 : /* 176 */ array(),
648 : /* 177 */ array(),
649 : /* 178 */ array(),
650 : /* 179 */ array(),
651 : /* 180 */ array(),
652 : /* 181 */ array(),
653 : /* 182 */ array(),
654 : /* 183 */ array(),
655 : /* 184 */ array(),
656 : /* 185 */ array(),
657 : /* 186 */ array(),
658 : /* 187 */ array(),
659 : /* 188 */ array(),
660 : /* 189 */ array(),
661 : /* 190 */ array(),
662 : /* 191 */ array(),
663 : /* 192 */ array(),
664 : /* 193 */ array(),
665 : /* 194 */ array(),
666 : /* 195 */ array(),
667 : /* 196 */ array(),
668 : /* 197 */ array(),
669 : /* 198 */ array(),
670 : /* 199 */ array(),
671 : /* 200 */ array(),
672 : /* 201 */ array(),
673 : /* 202 */ array(),
674 : /* 203 */ array(),
675 : /* 204 */ array(),
676 : /* 205 */ array(),
677 : /* 206 */ array(),
678 : /* 207 */ array(),
679 : /* 208 */ array(),
680 : /* 209 */ array(),
681 : /* 210 */ array(),
682 : /* 211 */ array(),
683 : /* 212 */ array(),
684 : /* 213 */ array(),
685 : /* 214 */ array(),
686 : /* 215 */ array(),
687 : /* 216 */ array(),
688 : /* 217 */ array(),
689 : /* 218 */ array(),
690 : /* 219 */ array(),
691 : /* 220 */ array(),
692 : /* 221 */ array(),
693 : /* 222 */ array(),
694 : /* 223 */ array(),
695 : /* 224 */ array(),
696 : /* 225 */ array(),
697 : /* 226 */ array(),
698 : /* 227 */ array(),
699 : /* 228 */ array(),
700 : /* 229 */ array(),
701 : /* 230 */ array(),
702 : /* 231 */ array(),
703 : /* 232 */ array(),
704 : /* 233 */ array(),
705 : /* 234 */ array(),
706 : /* 235 */ array(),
707 : /* 236 */ array(),
708 : /* 237 */ array(),
709 : );
710 : static public $yy_default = array(
711 : /* 0 */ 371, 371, 371, 371, 371, 371, 371, 371, 371, 371,
712 : /* 10 */ 371, 371, 357, 321, 321, 371, 321, 321, 371, 371,
713 : /* 20 */ 371, 371, 371, 371, 371, 371, 371, 371, 371, 371,
714 : /* 30 */ 371, 371, 371, 371, 371, 371, 266, 371, 299, 297,
715 : /* 40 */ 266, 266, 238, 331, 331, 303, 371, 303, 303, 371,
716 : /* 50 */ 266, 371, 371, 371, 371, 371, 371, 371, 371, 371,
717 : /* 60 */ 293, 371, 292, 266, 371, 371, 371, 334, 338, 329,
718 : /* 70 */ 333, 343, 339, 335, 342, 371, 305, 371, 371, 371,
719 : /* 80 */ 272, 371, 371, 327, 371, 358, 371, 371, 315, 371,
720 : /* 90 */ 371, 320, 371, 371, 371, 371, 332, 303, 270, 298,
721 : /* 100 */ 371, 312, 260, 267, 295, 360, 359, 294, 273, 303,
722 : /* 110 */ 371, 325, 325, 271, 271, 371, 326, 271, 304, 371,
723 : /* 120 */ 371, 371, 371, 371, 371, 371, 371, 371, 371, 371,
724 : /* 130 */ 371, 371, 371, 371, 371, 371, 371, 371, 371, 296,
725 : /* 140 */ 371, 371, 371, 371, 371, 352, 353, 281, 240, 330,
726 : /* 150 */ 256, 283, 286, 337, 257, 239, 285, 340, 276, 284,
727 : /* 160 */ 341, 282, 242, 369, 269, 247, 336, 370, 246, 243,
728 : /* 170 */ 244, 245, 262, 261, 302, 274, 368, 241, 367, 268,
729 : /* 180 */ 263, 248, 259, 275, 347, 310, 323, 309, 300, 354,
730 : /* 190 */ 311, 308, 251, 264, 322, 250, 249, 287, 356, 318,
731 : /* 200 */ 316, 291, 306, 307, 313, 366, 355, 319, 317, 365,
732 : /* 210 */ 265, 252, 349, 350, 348, 362, 346, 351, 301, 288,
733 : /* 220 */ 277, 289, 328, 290, 345, 344, 324, 254, 279, 253,
734 : /* 230 */ 280, 255, 278, 361, 363, 364, 258, 314,
735 : );
736 : /* The next thing included is series of defines which control
737 : ** various aspects of the generated parser.
738 : ** self::YYNOCODE is a number which corresponds
739 : ** to no legal terminal or nonterminal number. This
740 : ** number is used to fill in empty slots of the hash
741 : ** table.
742 : ** self::YYFALLBACK If defined, this indicates that one or more tokens
743 : ** have fall-back values which should be used if the
744 : ** original value of the token will not parse.
745 : ** self::YYSTACKDEPTH is the maximum depth of the parser's stack.
746 : ** self::YYNSTATE the combined number of states.
747 : ** self::YYNRULE the number of rules in the grammar
748 : ** self::YYERRORSYMBOL is the code number of the error symbol. If not
749 : ** defined, then do no error processing.
750 : */
751 : const YYNOCODE = 107;
752 : const YYSTACKDEPTH = 100;
753 : const YYNSTATE = 238;
754 : const YYNRULE = 133;
755 : const YYERRORSYMBOL = 67;
756 : const YYERRSYMDT = 'yy0';
757 : const YYFALLBACK = 1;
758 : /** The next table maps tokens into fallback tokens. If a construct
759 : * like the following:
760 : *
761 : * %fallback ID X Y Z.
762 : *
763 : * appears in the grammer, then ID becomes a fallback token for X, Y,
764 : * and Z. Whenever one of the tokens X, Y, or Z is input to the parser
765 : * but it does not parse, the type of the token is changed to ID and
766 : * the parse is retried before an error is thrown.
767 : */
768 : static public $yyFallback = array(
769 : 0, /* $ => nothing */
770 : 0, /* OTHER => nothing */
771 : 1, /* LDELSLASH => OTHER */
772 : 1, /* LDEL => OTHER */
773 : 1, /* RDEL => OTHER */
774 : 1, /* XML => OTHER */
775 : 1, /* PHP => OTHER */
776 : 1, /* SHORTTAGSTART => OTHER */
777 : 1, /* SHORTTAGEND => OTHER */
778 : 1, /* COMMENTEND => OTHER */
779 : 1, /* COMMENTSTART => OTHER */
780 : 1, /* NUMBER => OTHER */
781 : 1, /* MATH => OTHER */
782 : 1, /* UNIMATH => OTHER */
783 : 1, /* INCDEC => OTHER */
784 : 1, /* OPENP => OTHER */
785 : 1, /* CLOSEP => OTHER */
786 : 1, /* OPENB => OTHER */
787 : 1, /* CLOSEB => OTHER */
788 : 1, /* DOLLAR => OTHER */
789 : 1, /* DOT => OTHER */
790 : 1, /* COMMA => OTHER */
791 : 1, /* COLON => OTHER */
792 : 1, /* DOUBLECOLON => OTHER */
793 : 1, /* SEMICOLON => OTHER */
794 : 1, /* VERT => OTHER */
795 : 1, /* EQUAL => OTHER */
796 : 1, /* SPACE => OTHER */
797 : 1, /* PTR => OTHER */
798 : 1, /* APTR => OTHER */
799 : 1, /* ID => OTHER */
800 : 1, /* EQUALS => OTHER */
801 : 1, /* NOTEQUALS => OTHER */
802 : 1, /* GREATERTHAN => OTHER */
803 : 1, /* LESSTHAN => OTHER */
804 : 1, /* GREATEREQUAL => OTHER */
805 : 1, /* LESSEQUAL => OTHER */
806 : 1, /* IDENTITY => OTHER */
807 : 1, /* NONEIDENTITY => OTHER */
808 : 1, /* NOT => OTHER */
809 : 1, /* LAND => OTHER */
810 : 1, /* LOR => OTHER */
811 : 1, /* QUOTE => OTHER */
812 : 1, /* SINGLEQUOTE => OTHER */
813 : 1, /* BOOLEAN => OTHER */
814 : 1, /* NULL => OTHER */
815 : 1, /* IN => OTHER */
816 : 1, /* ANDSYM => OTHER */
817 : 1, /* BACKTICK => OTHER */
818 : 1, /* HATCH => OTHER */
819 : 1, /* AT => OTHER */
820 : 1, /* ISODD => OTHER */
821 : 1, /* ISNOTODD => OTHER */
822 : 1, /* ISEVEN => OTHER */
823 : 1, /* ISNOTEVEN => OTHER */
824 : 1, /* ISODDBY => OTHER */
825 : 1, /* ISNOTODDBY => OTHER */
826 : 1, /* ISEVENBY => OTHER */
827 : 1, /* ISNOTEVENBY => OTHER */
828 : 1, /* ISDIVBY => OTHER */
829 : 1, /* ISNOTDIVBY => OTHER */
830 : 0, /* LITERALSTART => nothing */
831 : 0, /* LITERALEND => nothing */
832 : 0, /* LDELIMTAG => nothing */
833 : 0, /* RDELIMTAG => nothing */
834 : 0, /* PHPSTART => nothing */
835 : 0, /* PHPEND => nothing */
836 : );
837 : /**
838 : * Turn parser tracing on by giving a stream to which to write the trace
839 : * and a prompt to preface each trace message. Tracing is turned off
840 : * by making either argument NULL
841 : *
842 : * Inputs:
843 : *
844 : * - A stream resource to which trace output should be written.
845 : * If NULL, then tracing is turned off.
846 : * - A prefix string written at the beginning of every
847 : * line of trace output. If NULL, then tracing is
848 : * turned off.
849 : *
850 : * Outputs:
851 : *
852 : * - None.
853 : * @param resource
854 : * @param string
855 : */
856 : static function Trace($TraceFILE, $zTracePrompt)
857 : {
858 0 : if (!$TraceFILE) {
859 0 : $zTracePrompt = 0;
860 0 : } elseif (!$zTracePrompt) {
861 0 : $TraceFILE = 0;
862 0 : }
863 0 : self::$yyTraceFILE = $TraceFILE;
864 0 : self::$yyTracePrompt = $zTracePrompt;
865 0 : }
866 :
867 : /**
868 : * Output debug information to output (php://output stream)
869 : */
870 : static function PrintTrace()
871 : {
872 0 : self::$yyTraceFILE = fopen('php://output', 'w');
873 0 : self::$yyTracePrompt = '<br>';
874 0 : }
875 :
876 : /**
877 : * @var resource|0
878 : */
879 : static public $yyTraceFILE;
880 : /**
881 : * String to prepend to debug output
882 : * @var string|0
883 : */
884 : static public $yyTracePrompt;
885 : /**
886 : * @var int
887 : */
888 : public $yyidx; /* Index of top element in stack */
889 : /**
890 : * @var int
891 : */
892 : public $yyerrcnt; /* Shifts left before out of the error */
893 : /**
894 : * @var array
895 : */
896 : public $yystack = array(); /* The parser's stack */
897 :
898 : /**
899 : * For tracing shifts, the names of all terminals and nonterminals
900 : * are required. The following table supplies these names
901 : * @var array
902 : */
903 : public $yyTokenName = array(
904 : '$', 'OTHER', 'LDELSLASH', 'LDEL',
905 : 'RDEL', 'XML', 'PHP', 'SHORTTAGSTART',
906 : 'SHORTTAGEND', 'COMMENTEND', 'COMMENTSTART', 'NUMBER',
907 : 'MATH', 'UNIMATH', 'INCDEC', 'OPENP',
908 : 'CLOSEP', 'OPENB', 'CLOSEB', 'DOLLAR',
909 : 'DOT', 'COMMA', 'COLON', 'DOUBLECOLON',
910 : 'SEMICOLON', 'VERT', 'EQUAL', 'SPACE',
911 : 'PTR', 'APTR', 'ID', 'EQUALS',
912 : 'NOTEQUALS', 'GREATERTHAN', 'LESSTHAN', 'GREATEREQUAL',
913 : 'LESSEQUAL', 'IDENTITY', 'NONEIDENTITY', 'NOT',
914 : 'LAND', 'LOR', 'QUOTE', 'SINGLEQUOTE',
915 : 'BOOLEAN', 'NULL', 'IN', 'ANDSYM',
916 : 'BACKTICK', 'HATCH', 'AT', 'ISODD',
917 : 'ISNOTODD', 'ISEVEN', 'ISNOTEVEN', 'ISODDBY',
918 : 'ISNOTODDBY', 'ISEVENBY', 'ISNOTEVENBY', 'ISDIVBY',
919 : 'ISNOTDIVBY', 'LITERALSTART', 'LITERALEND', 'LDELIMTAG',
920 : 'RDELIMTAG', 'PHPSTART', 'PHPEND', 'error',
921 : 'start', 'template', 'template_element', 'smartytag',
922 : 'text', 'variable', 'expr', 'attributes',
923 : 'statement', 'modifier', 'modparameters', 'ifexprs',
924 : 'statements', 'varvar', 'foraction', 'value',
925 : 'array', 'attribute', 'exprs', 'math',
926 : 'function', 'doublequoted', 'method', 'params',
927 : 'objectchain', 'arrayindex', 'object', 'indexdef',
928 : 'varvarele', 'objectelement', 'modparameter', 'ifexpr',
929 : 'ifcond', 'lop', 'arrayelements', 'arrayelement',
930 : 'doublequotedcontent', 'textelement',
931 : );
932 :
933 : /**
934 : * For tracing reduce actions, the names of all rules are required.
935 : * @var array
936 : */
937 : static public $yyRuleName = array(
938 : /* 0 */ "start ::= template",
939 : /* 1 */ "template ::= template_element",
940 : /* 2 */ "template ::= template template_element",
941 : /* 3 */ "template_element ::= smartytag",
942 : /* 4 */ "template_element ::= COMMENTSTART text COMMENTEND",
943 : /* 5 */ "template_element ::= LITERALSTART text LITERALEND",
944 : /* 6 */ "template_element ::= LDELIMTAG",
945 : /* 7 */ "template_element ::= RDELIMTAG",
946 : /* 8 */ "template_element ::= PHP",
947 : /* 9 */ "template_element ::= PHPSTART text PHPEND",
948 : /* 10 */ "template_element ::= SHORTTAGSTART variable SHORTTAGEND",
949 : /* 11 */ "template_element ::= XML",
950 : /* 12 */ "template_element ::= OTHER",
951 : /* 13 */ "smartytag ::= LDEL expr attributes RDEL",
952 : /* 14 */ "smartytag ::= LDEL statement RDEL",
953 : /* 15 */ "smartytag ::= LDEL ID attributes RDEL",
954 : /* 16 */ "smartytag ::= LDEL ID PTR ID attributes RDEL",
955 : /* 17 */ "smartytag ::= LDEL ID modifier modparameters attributes RDEL",
956 : /* 18 */ "smartytag ::= LDELSLASH ID attributes RDEL",
957 : /* 19 */ "smartytag ::= LDELSLASH ID PTR ID RDEL",
958 : /* 20 */ "smartytag ::= LDEL ID SPACE ifexprs RDEL",
959 : /* 21 */ "smartytag ::= LDEL ID SPACE statements SEMICOLON ifexprs SEMICOLON DOLLAR varvar foraction RDEL",
960 : /* 22 */ "foraction ::= EQUAL expr",
961 : /* 23 */ "foraction ::= INCDEC",
962 : /* 24 */ "smartytag ::= LDEL ID SPACE DOLLAR varvar IN value RDEL",
963 : /* 25 */ "smartytag ::= LDEL ID SPACE DOLLAR varvar IN array RDEL",
964 : /* 26 */ "attributes ::= attributes attribute",
965 : /* 27 */ "attributes ::= attribute",
966 : /* 28 */ "attributes ::=",
967 : /* 29 */ "attribute ::= SPACE ID EQUAL expr",
968 : /* 30 */ "statements ::= statement",
969 : /* 31 */ "statements ::= statements COMMA statement",
970 : /* 32 */ "statement ::= DOLLAR varvar EQUAL expr",
971 : /* 33 */ "expr ::= ID",
972 : /* 34 */ "expr ::= exprs",
973 : /* 35 */ "expr ::= expr modifier modparameters",
974 : /* 36 */ "exprs ::= array",
975 : /* 37 */ "exprs ::= value",
976 : /* 38 */ "exprs ::= UNIMATH value",
977 : /* 39 */ "exprs ::= exprs math value",
978 : /* 40 */ "exprs ::= exprs ANDSYM value",
979 : /* 41 */ "math ::= UNIMATH",
980 : /* 42 */ "math ::= MATH",
981 : /* 43 */ "value ::= variable",
982 : /* 44 */ "value ::= HATCH ID HATCH",
983 : /* 45 */ "value ::= NUMBER",
984 : /* 46 */ "value ::= BOOLEAN",
985 : /* 47 */ "value ::= NULL",
986 : /* 48 */ "value ::= function",
987 : /* 49 */ "value ::= OPENP expr CLOSEP",
988 : /* 50 */ "value ::= SINGLEQUOTE text SINGLEQUOTE",
989 : /* 51 */ "value ::= SINGLEQUOTE SINGLEQUOTE",
990 : /* 52 */ "value ::= QUOTE doublequoted QUOTE",
991 : /* 53 */ "value ::= QUOTE QUOTE",
992 : /* 54 */ "value ::= ID DOUBLECOLON method",
993 : /* 55 */ "value ::= ID DOUBLECOLON DOLLAR ID OPENP params CLOSEP",
994 : /* 56 */ "value ::= ID DOUBLECOLON method objectchain",
995 : /* 57 */ "value ::= ID DOUBLECOLON DOLLAR ID OPENP params CLOSEP objectchain",
996 : /* 58 */ "value ::= ID DOUBLECOLON ID",
997 : /* 59 */ "value ::= ID DOUBLECOLON DOLLAR ID arrayindex",
998 : /* 60 */ "value ::= ID DOUBLECOLON DOLLAR ID arrayindex objectchain",
999 : /* 61 */ "variable ::= DOLLAR varvar arrayindex",
1000 : /* 62 */ "variable ::= DOLLAR varvar AT ID",
1001 : /* 63 */ "variable ::= object",
1002 : /* 64 */ "arrayindex ::= arrayindex indexdef",
1003 : /* 65 */ "arrayindex ::=",
1004 : /* 66 */ "indexdef ::= DOT ID",
1005 : /* 67 */ "indexdef ::= DOT exprs",
1006 : /* 68 */ "indexdef ::= OPENB ID CLOSEB",
1007 : /* 69 */ "indexdef ::= OPENB exprs CLOSEB",
1008 : /* 70 */ "varvar ::= varvarele",
1009 : /* 71 */ "varvar ::= varvar varvarele",
1010 : /* 72 */ "varvarele ::= ID",
1011 : /* 73 */ "varvarele ::= LDEL expr RDEL",
1012 : /* 74 */ "object ::= DOLLAR varvar arrayindex objectchain",
1013 : /* 75 */ "objectchain ::= objectelement",
1014 : /* 76 */ "objectchain ::= objectchain objectelement",
1015 : /* 77 */ "objectelement ::= PTR ID arrayindex",
1016 : /* 78 */ "objectelement ::= PTR method",
1017 : /* 79 */ "function ::= ID OPENP params CLOSEP",
1018 : /* 80 */ "method ::= ID OPENP params CLOSEP",
1019 : /* 81 */ "params ::= expr COMMA params",
1020 : /* 82 */ "params ::= expr",
1021 : /* 83 */ "params ::=",
1022 : /* 84 */ "modifier ::= VERT AT ID",
1023 : /* 85 */ "modifier ::= VERT ID",
1024 : /* 86 */ "modparameters ::= modparameters modparameter",
1025 : /* 87 */ "modparameters ::=",
1026 : /* 88 */ "modparameter ::= COLON ID",
1027 : /* 89 */ "modparameter ::= COLON exprs",
1028 : /* 90 */ "ifexprs ::= ifexpr",
1029 : /* 91 */ "ifexprs ::= NOT ifexprs",
1030 : /* 92 */ "ifexprs ::= OPENP ifexprs CLOSEP",
1031 : /* 93 */ "ifexpr ::= expr",
1032 : /* 94 */ "ifexpr ::= expr ifcond expr",
1033 : /* 95 */ "ifexpr ::= ifexprs lop ifexprs",
1034 : /* 96 */ "ifexpr ::= ifexprs ISDIVBY ifexprs",
1035 : /* 97 */ "ifexpr ::= ifexprs ISNOTDIVBY ifexprs",
1036 : /* 98 */ "ifexpr ::= ifexprs ISEVEN",
1037 : /* 99 */ "ifexpr ::= ifexprs ISNOTEVEN",
1038 : /* 100 */ "ifexpr ::= ifexprs ISEVENBY ifexprs",
1039 : /* 101 */ "ifexpr ::= ifexprs ISNOTEVENBY ifexprs",
1040 : /* 102 */ "ifexpr ::= ifexprs ISODD",
1041 : /* 103 */ "ifexpr ::= ifexprs ISNOTODD",
1042 : /* 104 */ "ifexpr ::= ifexprs ISODDBY ifexprs",
1043 : /* 105 */ "ifexpr ::= ifexprs ISNOTODDBY ifexprs",
1044 : /* 106 */ "ifcond ::= EQUALS",
1045 : /* 107 */ "ifcond ::= NOTEQUALS",
1046 : /* 108 */ "ifcond ::= GREATERTHAN",
1047 : /* 109 */ "ifcond ::= LESSTHAN",
1048 : /* 110 */ "ifcond ::= GREATEREQUAL",
1049 : /* 111 */ "ifcond ::= LESSEQUAL",
1050 : /* 112 */ "ifcond ::= IDENTITY",
1051 : /* 113 */ "ifcond ::= NONEIDENTITY",
1052 : /* 114 */ "lop ::= LAND",
1053 : /* 115 */ "lop ::= LOR",
1054 : /* 116 */ "array ::= OPENB arrayelements CLOSEB",
1055 : /* 117 */ "arrayelements ::= arrayelement",
1056 : /* 118 */ "arrayelements ::= arrayelements COMMA arrayelement",
1057 : /* 119 */ "arrayelements ::=",
1058 : /* 120 */ "arrayelement ::= expr",
1059 : /* 121 */ "arrayelement ::= expr APTR expr",
1060 : /* 122 */ "arrayelement ::= ID APTR expr",
1061 : /* 123 */ "doublequoted ::= doublequoted doublequotedcontent",
1062 : /* 124 */ "doublequoted ::= doublequotedcontent",
1063 : /* 125 */ "doublequotedcontent ::= variable",
1064 : /* 126 */ "doublequotedcontent ::= BACKTICK variable BACKTICK",
1065 : /* 127 */ "doublequotedcontent ::= LDEL expr RDEL",
1066 : /* 128 */ "doublequotedcontent ::= OTHER",
1067 : /* 129 */ "text ::= text textelement",
1068 : /* 130 */ "text ::= textelement",
1069 : /* 131 */ "textelement ::= OTHER",
1070 : /* 132 */ "textelement ::= LDEL",
1071 : );
1072 :
1073 : /**
1074 : * This function returns the symbolic name associated with a token
1075 : * value.
1076 : * @param int
1077 : * @return string
1078 : */
1079 : function tokenName($tokenType)
1080 : {
1081 0 : if ($tokenType === 0) {
1082 0 : return 'End of Input';
1083 : }
1084 0 : if ($tokenType > 0 && $tokenType < count($this->yyTokenName)) {
1085 0 : return $this->yyTokenName[$tokenType];
1086 : } else {
1087 0 : return "Unknown";
1088 : }
1089 : }
1090 :
1091 : /**
1092 : * The following function deletes the value associated with a
1093 : * symbol. The symbol can be either a terminal or nonterminal.
1094 : * @param int the symbol code
1095 : * @param mixed the symbol's value
1096 : */
1097 : static function yy_destructor($yymajor, $yypminor)
1098 : {
1099 : switch ($yymajor) {
1100 : /* Here is inserted the actions which take place when a
1101 : ** terminal or non-terminal is destroyed. This can happen
1102 : ** when the symbol is popped from the stack during a
1103 : ** reduce or during error processing or when a parser is
1104 : ** being destroyed before it is finished parsing.
1105 : **
1106 : ** Note: during a reduce, the only symbols destroyed are those
1107 : ** which appear on the RHS of the rule, but which are not used
1108 : ** inside the C code.
1109 : */
1110 268 : default: break; /* If no destructor action specified: do nothing */
1111 268 : }
1112 268 : }
1113 :
1114 : /**
1115 : * Pop the parser's stack once.
1116 : *
1117 : * If there is a destructor routine associated with the token which
1118 : * is popped from the stack, then call it.
1119 : *
1120 : * Return the major token number for the symbol popped.
1121 : * @param TP_yyParser
1122 : * @return int
1123 : */
1124 : function yy_pop_parser_stack()
1125 : {
1126 268 : if (!count($this->yystack)) {
1127 0 : return;
1128 : }
1129 268 : $yytos = array_pop($this->yystack);
1130 268 : if (self::$yyTraceFILE && $this->yyidx >= 0) {
1131 0 : fwrite(self::$yyTraceFILE,
1132 0 : self::$yyTracePrompt . 'Popping ' . $this->yyTokenName[$yytos->major] .
1133 0 : "\n");
1134 0 : }
1135 268 : $yymajor = $yytos->major;
1136 268 : self::yy_destructor($yymajor, $yytos->minor);
1137 268 : $this->yyidx--;
1138 268 : return $yymajor;
1139 : }
1140 :
1141 : /**
1142 : * Deallocate and destroy a parser. Destructors are all called for
1143 : * all stack elements before shutting the parser down.
1144 : */
1145 : function __destruct()
1146 : {
1147 267 : while ($this->yyidx >= 0) {
1148 2 : $this->yy_pop_parser_stack();
1149 2 : }
1150 267 : if (is_resource(self::$yyTraceFILE)) {
1151 0 : fclose(self::$yyTraceFILE);
1152 0 : }
1153 267 : }
1154 :
1155 : /**
1156 : * Based on the current state and parser stack, get a list of all
1157 : * possible lookahead tokens
1158 : * @param int
1159 : * @return array
1160 : */
1161 : function yy_get_expected_tokens($token)
1162 : {
1163 1 : $state = $this->yystack[$this->yyidx]->stateno;
1164 1 : $expected = self::$yyExpectedTokens[$state];
1165 1 : if (in_array($token, self::$yyExpectedTokens[$state], true)) {
1166 0 : return $expected;
1167 : }
1168 1 : $stack = $this->yystack;
1169 1 : $yyidx = $this->yyidx;
1170 : do {
1171 1 : $yyact = $this->yy_find_shift_action($token);
1172 1 : if ($yyact >= self::YYNSTATE && $yyact < self::YYNSTATE + self::YYNRULE) {
1173 : // reduce action
1174 0 : $done = 0;
1175 : do {
1176 0 : if ($done++ == 100) {
1177 0 : $this->yyidx = $yyidx;
1178 0 : $this->yystack = $stack;
1179 : // too much recursion prevents proper detection
1180 : // so give up
1181 0 : return array_unique($expected);
1182 : }
1183 0 : $yyruleno = $yyact - self::YYNSTATE;
1184 0 : $this->yyidx -= self::$yyRuleInfo[$yyruleno]['rhs'];
1185 0 : $nextstate = $this->yy_find_reduce_action(
1186 0 : $this->yystack[$this->yyidx]->stateno,
1187 0 : self::$yyRuleInfo[$yyruleno]['lhs']);
1188 0 : if (isset(self::$yyExpectedTokens[$nextstate])) {
1189 0 : $expected += self::$yyExpectedTokens[$nextstate];
1190 0 : if (in_array($token,
1191 0 : self::$yyExpectedTokens[$nextstate], true)) {
1192 0 : $this->yyidx = $yyidx;
1193 0 : $this->yystack = $stack;
1194 0 : return array_unique($expected);
1195 : }
1196 0 : }
1197 0 : if ($nextstate < self::YYNSTATE) {
1198 : // we need to shift a non-terminal
1199 0 : $this->yyidx++;
1200 0 : $x = new TP_yyStackEntry;
1201 0 : $x->stateno = $nextstate;
1202 0 : $x->major = self::$yyRuleInfo[$yyruleno]['lhs'];
1203 0 : $this->yystack[$this->yyidx] = $x;
1204 0 : continue 2;
1205 0 : } elseif ($nextstate == self::YYNSTATE + self::YYNRULE + 1) {
1206 0 : $this->yyidx = $yyidx;
1207 0 : $this->yystack = $stack;
1208 : // the last token was just ignored, we can't accept
1209 : // by ignoring input, this is in essence ignoring a
1210 : // syntax error!
1211 0 : return array_unique($expected);
1212 0 : } elseif ($nextstate === self::YY_NO_ACTION) {
1213 0 : $this->yyidx = $yyidx;
1214 0 : $this->yystack = $stack;
1215 : // input accepted, but not shifted (I guess)
1216 0 : return $expected;
1217 : } else {
1218 0 : $yyact = $nextstate;
1219 : }
1220 0 : } while (true);
1221 0 : }
1222 1 : break;
1223 0 : } while (true);
1224 1 : return array_unique($expected);
1225 : }
1226 :
1227 : /**
1228 : * Based on the parser state and current parser stack, determine whether
1229 : * the lookahead token is possible.
1230 : *
1231 : * The parser will convert the token value to an error token if not. This
1232 : * catches some unusual edge cases where the parser would fail.
1233 : * @param int
1234 : * @return bool
1235 : */
1236 : function yy_is_expected_token($token)
1237 : {
1238 278 : if ($token === 0) {
1239 272 : return true; // 0 is not part of this
1240 : }
1241 278 : $state = $this->yystack[$this->yyidx]->stateno;
1242 278 : if (in_array($token, self::$yyExpectedTokens[$state], true)) {
1243 264 : return true;
1244 : }
1245 273 : $stack = $this->yystack;
1246 273 : $yyidx = $this->yyidx;
1247 : do {
1248 273 : $yyact = $this->yy_find_shift_action($token);
1249 273 : if ($yyact >= self::YYNSTATE && $yyact < self::YYNSTATE + self::YYNRULE) {
1250 : // reduce action
1251 272 : $done = 0;
1252 : do {
1253 272 : if ($done++ == 100) {
1254 0 : $this->yyidx = $yyidx;
1255 0 : $this->yystack = $stack;
1256 : // too much recursion prevents proper detection
1257 : // so give up
1258 0 : return true;
1259 : }
1260 272 : $yyruleno = $yyact - self::YYNSTATE;
1261 272 : $this->yyidx -= self::$yyRuleInfo[$yyruleno]['rhs'];
1262 272 : $nextstate = $this->yy_find_reduce_action(
1263 272 : $this->yystack[$this->yyidx]->stateno,
1264 272 : self::$yyRuleInfo[$yyruleno]['lhs']);
1265 272 : if (isset(self::$yyExpectedTokens[$nextstate]) &&
1266 272 : in_array($token, self::$yyExpectedTokens[$nextstate], true)) {
1267 258 : $this->yyidx = $yyidx;
1268 258 : $this->yystack = $stack;
1269 258 : return true;
1270 : }
1271 270 : if ($nextstate < self::YYNSTATE) {
1272 : // we need to shift a non-terminal
1273 270 : $this->yyidx++;
1274 270 : $x = new TP_yyStackEntry;
1275 270 : $x->stateno = $nextstate;
1276 270 : $x->major = self::$yyRuleInfo[$yyruleno]['lhs'];
1277 270 : $this->yystack[$this->yyidx] = $x;
1278 270 : continue 2;
1279 0 : } elseif ($nextstate == self::YYNSTATE + self::YYNRULE + 1) {
1280 0 : $this->yyidx = $yyidx;
1281 0 : $this->yystack = $stack;
1282 0 : if (!$token) {
1283 : // end of input: this is valid
1284 0 : return true;
1285 : }
1286 : // the last token was just ignored, we can't accept
1287 : // by ignoring input, this is in essence ignoring a
1288 : // syntax error!
1289 0 : return false;
1290 0 : } elseif ($nextstate === self::YY_NO_ACTION) {
1291 0 : $this->yyidx = $yyidx;
1292 0 : $this->yystack = $stack;
1293 : // input accepted, but not shifted (I guess)
1294 0 : return true;
1295 : } else {
1296 0 : $yyact = $nextstate;
1297 : }
1298 0 : } while (true);
1299 0 : }
1300 212 : break;
1301 0 : } while (true);
1302 212 : $this->yyidx = $yyidx;
1303 212 : $this->yystack = $stack;
1304 212 : return true;
1305 : }
1306 :
1307 : /**
1308 : * Find the appropriate action for a parser given the terminal
1309 : * look-ahead token iLookAhead.
1310 : *
1311 : * If the look-ahead token is YYNOCODE, then check to see if the action is
1312 : * independent of the look-ahead. If it is, return the action, otherwise
1313 : * return YY_NO_ACTION.
1314 : * @param int The look-ahead token
1315 : */
1316 : function yy_find_shift_action($iLookAhead)
1317 : {
1318 278 : $stateno = $this->yystack[$this->yyidx]->stateno;
1319 :
1320 : /* if ($this->yyidx < 0) return self::YY_NO_ACTION; */
1321 278 : if (!isset(self::$yy_shift_ofst[$stateno])) {
1322 : // no shift actions
1323 277 : return self::$yy_default[$stateno];
1324 : }
1325 278 : $i = self::$yy_shift_ofst[$stateno];
1326 278 : if ($i === self::YY_SHIFT_USE_DFLT) {
1327 13 : return self::$yy_default[$stateno];
1328 : }
1329 278 : if ($iLookAhead == self::YYNOCODE) {
1330 0 : return self::YY_NO_ACTION;
1331 : }
1332 278 : $i += $iLookAhead;
1333 278 : if ($i < 0 || $i >= self::YY_SZ_ACTTAB ||
1334 278 : self::$yy_lookahead[$i] != $iLookAhead) {
1335 278 : if (count(self::$yyFallback) && $iLookAhead < count(self::$yyFallback)
1336 278 : && ($iFallback = self::$yyFallback[$iLookAhead]) != 0) {
1337 273 : if (self::$yyTraceFILE) {
1338 0 : fwrite(self::$yyTraceFILE, self::$yyTracePrompt . "FALLBACK " .
1339 0 : $this->yyTokenName[$iLookAhead] . " => " .
1340 0 : $this->yyTokenName[$iFallback] . "\n");
1341 0 : }
1342 273 : return $this->yy_find_shift_action($iFallback);
1343 : }
1344 278 : return self::$yy_default[$stateno];
1345 : } else {
1346 278 : return self::$yy_action[$i];
1347 : }
1348 : }
1349 :
1350 : /**
1351 : * Find the appropriate action for a parser given the non-terminal
1352 : * look-ahead token $iLookAhead.
1353 : *
1354 : * If the look-ahead token is self::YYNOCODE, then check to see if the action is
1355 : * independent of the look-ahead. If it is, return the action, otherwise
1356 : * return self::YY_NO_ACTION.
1357 : * @param int Current state number
1358 : * @param int The look-ahead token
1359 : */
1360 : function yy_find_reduce_action($stateno, $iLookAhead)
1361 : {
1362 : /* $stateno = $this->yystack[$this->yyidx]->stateno; */
1363 :
1364 277 : if (!isset(self::$yy_reduce_ofst[$stateno])) {
1365 0 : return self::$yy_default[$stateno];
1366 : }
1367 277 : $i = self::$yy_reduce_ofst[$stateno];
1368 277 : if ($i == self::YY_REDUCE_USE_DFLT) {
1369 0 : return self::$yy_default[$stateno];
1370 : }
1371 277 : if ($iLookAhead == self::YYNOCODE) {
1372 0 : return self::YY_NO_ACTION;
1373 : }
1374 277 : $i += $iLookAhead;
1375 277 : if ($i < 0 || $i >= self::YY_SZ_ACTTAB ||
1376 277 : self::$yy_lookahead[$i] != $iLookAhead) {
1377 0 : return self::$yy_default[$stateno];
1378 : } else {
1379 277 : return self::$yy_action[$i];
1380 : }
1381 : }
1382 :
1383 : /**
1384 : * Perform a shift action.
1385 : * @param int The new state to shift in
1386 : * @param int The major token to shift in
1387 : * @param mixed the minor token to shift in
1388 : */
1389 : function yy_shift($yyNewState, $yyMajor, $yypMinor)
1390 : {
1391 278 : $this->yyidx++;
1392 278 : if ($this->yyidx >= self::YYSTACKDEPTH) {
1393 0 : $this->yyidx--;
1394 0 : if (self::$yyTraceFILE) {
1395 0 : fprintf(self::$yyTraceFILE, "%sStack Overflow!\n", self::$yyTracePrompt);
1396 0 : }
1397 0 : while ($this->yyidx >= 0) {
1398 0 : $this->yy_pop_parser_stack();
1399 0 : }
1400 : /* Here code is inserted which will execute if the parser
1401 : ** stack ever overflows */
1402 0 : return;
1403 : }
1404 278 : $yytos = new TP_yyStackEntry;
1405 278 : $yytos->stateno = $yyNewState;
1406 278 : $yytos->major = $yyMajor;
1407 278 : $yytos->minor = $yypMinor;
1408 278 : array_push($this->yystack, $yytos);
1409 278 : if (self::$yyTraceFILE && $this->yyidx > 0) {
1410 0 : fprintf(self::$yyTraceFILE, "%sShift %d\n", self::$yyTracePrompt,
1411 0 : $yyNewState);
1412 0 : fprintf(self::$yyTraceFILE, "%sStack:", self::$yyTracePrompt);
1413 0 : for($i = 1; $i <= $this->yyidx; $i++) {
1414 0 : fprintf(self::$yyTraceFILE, " %s",
1415 0 : $this->yyTokenName[$this->yystack[$i]->major]);
1416 0 : }
1417 0 : fwrite(self::$yyTraceFILE,"\n");
1418 0 : }
1419 278 : }
1420 :
1421 : /**
1422 : * The following table contains information about every rule that
1423 : * is used during the reduce.
1424 : *
1425 : * <pre>
1426 : * array(
1427 : * array(
1428 : * int $lhs; Symbol on the left-hand side of the rule
1429 : * int $nrhs; Number of right-hand side symbols in the rule
1430 : * ),...
1431 : * );
1432 : * </pre>
1433 : */
1434 : static public $yyRuleInfo = array(
1435 : array( 'lhs' => 68, 'rhs' => 1 ),
1436 : array( 'lhs' => 69, 'rhs' => 1 ),
1437 : array( 'lhs' => 69, 'rhs' => 2 ),
1438 : array( 'lhs' => 70, 'rhs' => 1 ),
1439 : array( 'lhs' => 70, 'rhs' => 3 ),
1440 : array( 'lhs' => 70, 'rhs' => 3 ),
1441 : array( 'lhs' => 70, 'rhs' => 1 ),
1442 : array( 'lhs' => 70, 'rhs' => 1 ),
1443 : array( 'lhs' => 70, 'rhs' => 1 ),
1444 : array( 'lhs' => 70, 'rhs' => 3 ),
1445 : array( 'lhs' => 70, 'rhs' => 3 ),
1446 : array( 'lhs' => 70, 'rhs' => 1 ),
1447 : array( 'lhs' => 70, 'rhs' => 1 ),
1448 : array( 'lhs' => 71, 'rhs' => 4 ),
1449 : array( 'lhs' => 71, 'rhs' => 3 ),
1450 : array( 'lhs' => 71, 'rhs' => 4 ),
1451 : array( 'lhs' => 71, 'rhs' => 6 ),
1452 : array( 'lhs' => 71, 'rhs' => 6 ),
1453 : array( 'lhs' => 71, 'rhs' => 4 ),
1454 : array( 'lhs' => 71, 'rhs' => 5 ),
1455 : array( 'lhs' => 71, 'rhs' => 5 ),
1456 : array( 'lhs' => 71, 'rhs' => 11 ),
1457 : array( 'lhs' => 82, 'rhs' => 2 ),
1458 : array( 'lhs' => 82, 'rhs' => 1 ),
1459 : array( 'lhs' => 71, 'rhs' => 8 ),
1460 : array( 'lhs' => 71, 'rhs' => 8 ),
1461 : array( 'lhs' => 75, 'rhs' => 2 ),
1462 : array( 'lhs' => 75, 'rhs' => 1 ),
1463 : array( 'lhs' => 75, 'rhs' => 0 ),
1464 : array( 'lhs' => 85, 'rhs' => 4 ),
1465 : array( 'lhs' => 80, 'rhs' => 1 ),
1466 : array( 'lhs' => 80, 'rhs' => 3 ),
1467 : array( 'lhs' => 76, 'rhs' => 4 ),
1468 : array( 'lhs' => 74, 'rhs' => 1 ),
1469 : array( 'lhs' => 74, 'rhs' => 1 ),
1470 : array( 'lhs' => 74, 'rhs' => 3 ),
1471 : array( 'lhs' => 86, 'rhs' => 1 ),
1472 : array( 'lhs' => 86, 'rhs' => 1 ),
1473 : array( 'lhs' => 86, 'rhs' => 2 ),
1474 : array( 'lhs' => 86, 'rhs' => 3 ),
1475 : array( 'lhs' => 86, 'rhs' => 3 ),
1476 : array( 'lhs' => 87, 'rhs' => 1 ),
1477 : array( 'lhs' => 87, 'rhs' => 1 ),
1478 : array( 'lhs' => 83, 'rhs' => 1 ),
1479 : array( 'lhs' => 83, 'rhs' => 3 ),
1480 : array( 'lhs' => 83, 'rhs' => 1 ),
1481 : array( 'lhs' => 83, 'rhs' => 1 ),
1482 : array( 'lhs' => 83, 'rhs' => 1 ),
1483 : array( 'lhs' => 83, 'rhs' => 1 ),
1484 : array( 'lhs' => 83, 'rhs' => 3 ),
1485 : array( 'lhs' => 83, 'rhs' => 3 ),
1486 : array( 'lhs' => 83, 'rhs' => 2 ),
1487 : array( 'lhs' => 83, 'rhs' => 3 ),
1488 : array( 'lhs' => 83, 'rhs' => 2 ),
1489 : array( 'lhs' => 83, 'rhs' => 3 ),
1490 : array( 'lhs' => 83, 'rhs' => 7 ),
1491 : array( 'lhs' => 83, 'rhs' => 4 ),
1492 : array( 'lhs' => 83, 'rhs' => 8 ),
1493 : array( 'lhs' => 83, 'rhs' => 3 ),
1494 : array( 'lhs' => 83, 'rhs' => 5 ),
1495 : array( 'lhs' => 83, 'rhs' => 6 ),
1496 : array( 'lhs' => 73, 'rhs' => 3 ),
1497 : array( 'lhs' => 73, 'rhs' => 4 ),
1498 : array( 'lhs' => 73, 'rhs' => 1 ),
1499 : array( 'lhs' => 93, 'rhs' => 2 ),
1500 : array( 'lhs' => 93, 'rhs' => 0 ),
1501 : array( 'lhs' => 95, 'rhs' => 2 ),
1502 : array( 'lhs' => 95, 'rhs' => 2 ),
1503 : array( 'lhs' => 95, 'rhs' => 3 ),
1504 : array( 'lhs' => 95, 'rhs' => 3 ),
1505 : array( 'lhs' => 81, 'rhs' => 1 ),
1506 : array( 'lhs' => 81, 'rhs' => 2 ),
1507 : array( 'lhs' => 96, 'rhs' => 1 ),
1508 : array( 'lhs' => 96, 'rhs' => 3 ),
1509 : array( 'lhs' => 94, 'rhs' => 4 ),
1510 : array( 'lhs' => 92, 'rhs' => 1 ),
1511 : array( 'lhs' => 92, 'rhs' => 2 ),
1512 : array( 'lhs' => 97, 'rhs' => 3 ),
1513 : array( 'lhs' => 97, 'rhs' => 2 ),
1514 : array( 'lhs' => 88, 'rhs' => 4 ),
1515 : array( 'lhs' => 90, 'rhs' => 4 ),
1516 : array( 'lhs' => 91, 'rhs' => 3 ),
1517 : array( 'lhs' => 91, 'rhs' => 1 ),
1518 : array( 'lhs' => 91, 'rhs' => 0 ),
1519 : array( 'lhs' => 77, 'rhs' => 3 ),
1520 : array( 'lhs' => 77, 'rhs' => 2 ),
1521 : array( 'lhs' => 78, 'rhs' => 2 ),
1522 : array( 'lhs' => 78, 'rhs' => 0 ),
1523 : array( 'lhs' => 98, 'rhs' => 2 ),
1524 : array( 'lhs' => 98, 'rhs' => 2 ),
1525 : array( 'lhs' => 79, 'rhs' => 1 ),
1526 : array( 'lhs' => 79, 'rhs' => 2 ),
1527 : array( 'lhs' => 79, 'rhs' => 3 ),
1528 : array( 'lhs' => 99, 'rhs' => 1 ),
1529 : array( 'lhs' => 99, 'rhs' => 3 ),
1530 : array( 'lhs' => 99, 'rhs' => 3 ),
1531 : array( 'lhs' => 99, 'rhs' => 3 ),
1532 : array( 'lhs' => 99, 'rhs' => 3 ),
1533 : array( 'lhs' => 99, 'rhs' => 2 ),
1534 : array( 'lhs' => 99, 'rhs' => 2 ),
1535 : array( 'lhs' => 99, 'rhs' => 3 ),
1536 : array( 'lhs' => 99, 'rhs' => 3 ),
1537 : array( 'lhs' => 99, 'rhs' => 2 ),
1538 : array( 'lhs' => 99, 'rhs' => 2 ),
1539 : array( 'lhs' => 99, 'rhs' => 3 ),
1540 : array( 'lhs' => 99, 'rhs' => 3 ),
1541 : array( 'lhs' => 100, 'rhs' => 1 ),
1542 : array( 'lhs' => 100, 'rhs' => 1 ),
1543 : array( 'lhs' => 100, 'rhs' => 1 ),
1544 : array( 'lhs' => 100, 'rhs' => 1 ),
1545 : array( 'lhs' => 100, 'rhs' => 1 ),
1546 : array( 'lhs' => 100, 'rhs' => 1 ),
1547 : array( 'lhs' => 100, 'rhs' => 1 ),
1548 : array( 'lhs' => 100, 'rhs' => 1 ),
1549 : array( 'lhs' => 101, 'rhs' => 1 ),
1550 : array( 'lhs' => 101, 'rhs' => 1 ),
1551 : array( 'lhs' => 84, 'rhs' => 3 ),
1552 : array( 'lhs' => 102, 'rhs' => 1 ),
1553 : array( 'lhs' => 102, 'rhs' => 3 ),
1554 : array( 'lhs' => 102, 'rhs' => 0 ),
1555 : array( 'lhs' => 103, 'rhs' => 1 ),
1556 : array( 'lhs' => 103, 'rhs' => 3 ),
1557 : array( 'lhs' => 103, 'rhs' => 3 ),
1558 : array( 'lhs' => 89, 'rhs' => 2 ),
1559 : array( 'lhs' => 89, 'rhs' => 1 ),
1560 : array( 'lhs' => 104, 'rhs' => 1 ),
1561 : array( 'lhs' => 104, 'rhs' => 3 ),
1562 : array( 'lhs' => 104, 'rhs' => 3 ),
1563 : array( 'lhs' => 104, 'rhs' => 1 ),
1564 : array( 'lhs' => 72, 'rhs' => 2 ),
1565 : array( 'lhs' => 72, 'rhs' => 1 ),
1566 : array( 'lhs' => 105, 'rhs' => 1 ),
1567 : array( 'lhs' => 105, 'rhs' => 1 ),
1568 : );
1569 :
1570 : /**
1571 : * The following table contains a mapping of reduce action to method name
1572 : * that handles the reduction.
1573 : *
1574 : * If a rule is not set, it has no handler.
1575 : */
1576 : static public $yyReduceMap = array(
1577 : 0 => 0,
1578 : 37 => 0,
1579 : 43 => 0,
1580 : 45 => 0,
1581 : 46 => 0,
1582 : 47 => 0,
1583 : 48 => 0,
1584 : 63 => 0,
1585 : 117 => 0,
1586 : 1 => 1,
1587 : 34 => 1,
1588 : 36 => 1,
1589 : 41 => 1,
1590 : 42 => 1,
1591 : 70 => 1,
1592 : 90 => 1,
1593 : 124 => 1,
1594 : 130 => 1,
1595 : 131 => 1,
1596 : 132 => 1,
1597 : 2 => 2,
1598 : 64 => 2,
1599 : 123 => 2,
1600 : 129 => 2,
1601 : 3 => 3,
1602 : 4 => 4,
1603 : 5 => 5,
1604 : 6 => 6,
1605 : 7 => 7,
1606 : 8 => 8,
1607 : 9 => 9,
1608 : 10 => 10,
1609 : 11 => 11,
1610 : 12 => 12,
1611 : 13 => 13,
1612 : 14 => 14,
1613 : 15 => 15,
1614 : 16 => 16,
1615 : 17 => 17,
1616 : 18 => 18,
1617 : 19 => 19,
1618 : 20 => 20,
1619 : 21 => 21,
1620 : 22 => 22,
1621 : 23 => 23,
1622 : 27 => 23,
1623 : 82 => 23,
1624 : 120 => 23,
1625 : 24 => 24,
1626 : 25 => 24,
1627 : 26 => 26,
1628 : 28 => 28,
1629 : 29 => 29,
1630 : 30 => 30,
1631 : 31 => 31,
1632 : 32 => 32,
1633 : 33 => 33,
1634 : 35 => 35,
1635 : 38 => 38,
1636 : 39 => 39,
1637 : 40 => 40,
1638 : 44 => 44,
1639 : 49 => 49,
1640 : 50 => 50,
1641 : 51 => 51,
1642 : 53 => 51,
1643 : 52 => 52,
1644 : 54 => 54,
1645 : 55 => 55,
1646 : 56 => 56,
1647 : 57 => 57,
1648 : 58 => 58,
1649 : 59 => 59,
1650 : 60 => 60,
1651 : 61 => 61,
1652 : 62 => 62,
1653 : 65 => 65,
1654 : 87 => 65,
1655 : 66 => 66,
1656 : 67 => 67,
1657 : 68 => 68,
1658 : 69 => 69,
1659 : 71 => 71,
1660 : 72 => 72,
1661 : 73 => 73,
1662 : 92 => 73,
1663 : 74 => 74,
1664 : 75 => 75,
1665 : 76 => 76,
1666 : 77 => 77,
1667 : 78 => 78,
1668 : 79 => 79,
1669 : 80 => 80,
1670 : 81 => 81,
1671 : 83 => 83,
1672 : 84 => 84,
1673 : 85 => 85,
1674 : 86 => 86,
1675 : 88 => 88,
1676 : 89 => 89,
1677 : 91 => 91,
1678 : 93 => 93,
1679 : 94 => 94,
1680 : 95 => 94,
1681 : 96 => 96,
1682 : 97 => 97,
1683 : 98 => 98,
1684 : 103 => 98,
1685 : 99 => 99,
1686 : 102 => 99,
1687 : 100 => 100,
1688 : 105 => 100,
1689 : 101 => 101,
1690 : 104 => 101,
1691 : 106 => 106,
1692 : 107 => 107,
1693 : 108 => 108,
1694 : 109 => 109,
1695 : 110 => 110,
1696 : 111 => 111,
1697 : 112 => 112,
1698 : 113 => 113,
1699 : 114 => 114,
1700 : 115 => 115,
1701 : 116 => 116,
1702 : 118 => 118,
1703 : 119 => 119,
1704 : 121 => 121,
1705 : 122 => 122,
1706 : 125 => 125,
1707 : 126 => 126,
1708 : 127 => 127,
1709 : 128 => 128,
1710 : );
1711 : /* Beginning here are the reduction cases. A typical example
1712 : ** follows:
1713 : ** #line <lineno> <grammarfile>
1714 : ** function yy_r0($yymsp){ ... } // User supplied code
1715 : ** #line <lineno> <thisfile>
1716 : */
1717 : #line 73 "internal.templateparser.y"
1718 274 : function yy_r0(){ $this->_retvalue = $this->yystack[$this->yyidx + 0]->minor; }
1719 : #line 1724 "internal.templateparser.php"
1720 : #line 79 "internal.templateparser.y"
1721 275 : function yy_r1(){$this->_retvalue = $this->yystack[$this->yyidx + 0]->minor; }
1722 : #line 1727 "internal.templateparser.php"
1723 : #line 81 "internal.templateparser.y"
1724 252 : function yy_r2(){$this->_retvalue = $this->yystack[$this->yyidx + -1]->minor.$this->yystack[$this->yyidx + 0]->minor; }
1725 : #line 1730 "internal.templateparser.php"
1726 : #line 87 "internal.templateparser.y"
1727 242 : function yy_r3(){if ($this->compiler->has_code) {
1728 242 : $tmp =''; foreach ($this->prefix_code as $code) {$tmp.=$code;} $this->prefix_code=array();
1729 242 : $this->_retvalue = $this->cacher->processNocacheCode($tmp.$this->yystack[$this->yyidx + 0]->minor, $this->compiler,$this->nocache,true);
1730 242 : } $this->nocache=false; }
1731 : #line 1736 "internal.templateparser.php"
1732 : #line 100 "internal.templateparser.y"
1733 8 : function yy_r4(){ $this->_retvalue = ''; }
1734 : #line 1739 "internal.templateparser.php"
1735 : #line 103 "internal.templateparser.y"
1736 0 : function yy_r5(){$this->_retvalue = $this->cacher->processNocacheCode($this->yystack[$this->yyidx + -1]->minor, $this->compiler,false,false); }
1737 : #line 1742 "internal.templateparser.php"
1738 : #line 105 "internal.templateparser.y"
1739 0 : function yy_r6(){$this->_retvalue = $this->cacher->processNocacheCode($this->smarty->left_delimiter, $this->compiler,false,false); }
1740 : #line 1745 "internal.templateparser.php"
1741 : #line 107 "internal.templateparser.y"
1742 0 : function yy_r7(){$this->_retvalue = $this->cacher->processNocacheCode($this->smarty->right_delimiter, $this->compiler,false,false); }
1743 : #line 1748 "internal.templateparser.php"
1744 : #line 109 "internal.templateparser.y"
1745 5 : function yy_r8(){if (!$this->template->security) {
1746 2 : $this->_retvalue = $this->cacher->processNocacheCode($this->yystack[$this->yyidx + 0]->minor, $this->compiler, false,true);
1747 5 : } elseif ($this->smarty->security_policy->php_handling == SMARTY_PHP_QUOTE) {
1748 1 : $this->_retvalue = $this->cacher->processNocacheCode(htmlspecialchars($this->yystack[$this->yyidx + 0]->minor, ENT_QUOTES), $this->compiler, false, false);
1749 3 : }elseif ($this->smarty->security_policy->php_handling == SMARTY_PHP_PASSTHRU || $this->smarty->security_policy->php_handling == SMARTY_PHP_ALLOW) {
1750 1 : $this->_retvalue = $this->cacher->processNocacheCode("<?php echo '".$this->yystack[$this->yyidx + 0]->minor."';?>\n", $this->compiler, false, false);
1751 2 : }elseif ($this->smarty->security_policy->php_handling == SMARTY_PHP_REMOVE) {
1752 1 : $this->_retvalue = '';
1753 5 : } }
1754 : #line 1759 "internal.templateparser.php"
1755 : #line 119 "internal.templateparser.y"
1756 4 : function yy_r9(){if (!$this->template->security) {
1757 1 : $this->_retvalue = $this->cacher->processNocacheCode('<?php '.$this->yystack[$this->yyidx + -1]->minor.' ?>', $this->compiler, false,true);
1758 4 : } elseif ($this->smarty->security_policy->php_handling == SMARTY_PHP_QUOTE) {
1759 1 : $this->_retvalue = $this->cacher->processNocacheCode(htmlspecialchars('<?php '.$this->yystack[$this->yyidx + -1]->minor.' ?>', ENT_QUOTES), $this->compiler, false, false);
1760 3 : }elseif ($this->smarty->security_policy->php_handling == SMARTY_PHP_PASSTHRU || $this->smarty->security_policy->php_handling == SMARTY_PHP_ALLOW) {
1761 1 : $this->_retvalue = $this->cacher->processNocacheCode("<?php echo '<?php ".$this->yystack[$this->yyidx + -1]->minor." ?>';?>\n", $this->compiler, false, false);
1762 2 : }elseif ($this->smarty->security_policy->php_handling == SMARTY_PHP_REMOVE) {
1763 1 : $this->_retvalue = '';
1764 4 : } }
1765 : #line 1770 "internal.templateparser.php"
1766 : #line 129 "internal.templateparser.y"
1767 1 : function yy_r10(){if (!$this->template->security) {
1768 1 : $this->_retvalue = $this->cacher->processNocacheCode($this->compiler->compileTag('print_expression',array('value'=>$this->yystack[$this->yyidx + -1]->minor)), $this->compiler, false,true);
1769 1 : } elseif ($this->smarty->security_policy->php_handling == SMARTY_PHP_QUOTE) {
1770 0 : $this->_retvalue = $this->cacher->processNocacheCode(htmlspecialchars('<?php '.t.' ?>', ENT_QUOTES), $this->compiler, false, false);
1771 0 : }elseif ($this->smarty->security_policy->php_handling == SMARTY_PHP_PASSTHRU || $this->smarty->security_policy->php_handling == SMARTY_PHP_ALLOW) {
1772 0 : $this->_retvalue = $this->cacher->processNocacheCode("<?php echo '<?php ".t." ?>';?>\n", $this->compiler, false, false);
1773 0 : }elseif ($this->smarty->security_policy->php_handling == SMARTY_PHP_REMOVE) {
1774 0 : $this->_retvalue = '';
1775 1 : } }
1776 : #line 1781 "internal.templateparser.php"
1777 : #line 139 "internal.templateparser.y"
1778 2 : function yy_r11(){$this->_retvalue = $this->cacher->processNocacheCode("<?php echo '".$this->yystack[$this->yyidx + 0]->minor."';?>\n", $this->compiler, true, true); }
1779 : #line 1784 "internal.templateparser.php"
1780 : #line 141 "internal.templateparser.y"
1781 154 : function yy_r12(){$this->_retvalue = $this->cacher->processNocacheCode($this->yystack[$this->yyidx + 0]->minor, $this->compiler,false,false); }
1782 : #line 1787 "internal.templateparser.php"
1783 : #line 149 "internal.templateparser.y"
1784 147 : function yy_r13(){ $this->_retvalue = $this->compiler->compileTag('print_expression',array_merge(array('value'=>$this->yystack[$this->yyidx + -2]->minor),$this->yystack[$this->yyidx + -1]->minor)); }
1785 : #line 1790 "internal.templateparser.php"
1786 : #line 151 "internal.templateparser.y"
1787 33 : function yy_r14(){ $this->_retvalue = $this->compiler->compileTag('assign',$this->yystack[$this->yyidx + -1]->minor); }
1788 : #line 1793 "internal.templateparser.php"
1789 : #line 153 "internal.templateparser.y"
1790 152 : function yy_r15(){ $this->_retvalue = $this->compiler->compileTag($this->yystack[$this->yyidx + -2]->minor,$this->yystack[$this->yyidx + -1]->minor); }
1791 : #line 1796 "internal.templateparser.php"
1792 : #line 155 "internal.templateparser.y"
1793 2 : function yy_r16(){ $this->_retvalue = $this->compiler->compileTag($this->yystack[$this->yyidx + -4]->minor,array_merge(array('object_methode'=>$this->yystack[$this->yyidx + -2]->minor),$this->yystack[$this->yyidx + -1]->minor)); }
1794 : #line 1799 "internal.templateparser.php"
1795 : #line 157 "internal.templateparser.y"
1796 1 : function yy_r17(){ $this->_retvalue = '<?php ob_start();?>'.$this->compiler->compileTag($this->yystack[$this->yyidx + -4]->minor,$this->yystack[$this->yyidx + -1]->minor).'<?php echo ';
1797 1 : if ($this->smarty->plugin_handler->loadSmartyPlugin($this->yystack[$this->yyidx + -3]->minor[0],'modifier')) {
1798 1 : $this->_retvalue .= "\$_smarty_tpl->smarty->plugin_handler->".$this->yystack[$this->yyidx + -3]->minor[0] . "(array(ob_get_clean()". $this->yystack[$this->yyidx + -2]->minor ."),'modifier');?>";
1799 1 : } else {
1800 0 : if ($this->yystack[$this->yyidx + -3]->minor[0] == 'isset' || $this->yystack[$this->yyidx + -3]->minor[0] == 'empty' || is_callable($this->yystack[$this->yyidx + -3]->minor[0])) {
1801 0 : if (!$this->template->security || $this->smarty->security_handler->isTrustedModifier($this->yystack[$this->yyidx + -3]->minor[0], $this->compiler)) {
1802 0 : $this->_retvalue .= $this->yystack[$this->yyidx + -3]->minor[0] . "(ob_get_clean()". $this->yystack[$this->yyidx + -2]->minor .");?>";
1803 0 : }
1804 0 : } else {
1805 0 : $this->compiler->trigger_template_error ("unknown modifier \"" . $this->yystack[$this->yyidx + -3]->minor[0] . "\"");
1806 : }
1807 : }
1808 1 : }
1809 : #line 1814 "internal.templateparser.php"
1810 : #line 171 "internal.templateparser.y"
1811 117 : function yy_r18(){ $this->_retvalue = $this->compiler->compileTag($this->yystack[$this->yyidx + -2]->minor.'close',$this->yystack[$this->yyidx + -1]->minor); }
1812 : #line 1817 "internal.templateparser.php"
1813 : #line 173 "internal.templateparser.y"
1814 1 : function yy_r19(){ $this->_retvalue = $this->compiler->compileTag($this->yystack[$this->yyidx + -3]->minor.'close',array('object_methode'=>$this->yystack[$this->yyidx + -1]->minor)); }
1815 : #line 1820 "internal.templateparser.php"
1816 : #line 175 "internal.templateparser.y"
1817 68 : function yy_r20(){ $this->_retvalue = $this->compiler->compileTag($this->yystack[$this->yyidx + -3]->minor,array('if condition'=>$this->yystack[$this->yyidx + -1]->minor)); }
1818 : #line 1823 "internal.templateparser.php"
1819 : #line 177 "internal.templateparser.y"
1820 7 : function yy_r21(){ $this->_retvalue = $this->compiler->compileTag($this->yystack[$this->yyidx + -9]->minor,array('start'=>$this->yystack[$this->yyidx + -7]->minor,'ifexp'=>$this->yystack[$this->yyidx + -5]->minor,'varloop'=>$this->yystack[$this->yyidx + -2]->minor,'loop'=>$this->yystack[$this->yyidx + -1]->minor)); }
1821 : #line 1826 "internal.templateparser.php"
1822 : #line 178 "internal.templateparser.y"
1823 1 : function yy_r22(){ $this->_retvalue = '='.$this->yystack[$this->yyidx + 0]->minor; }
1824 : #line 1829 "internal.templateparser.php"
1825 : #line 179 "internal.templateparser.y"
1826 103 : function yy_r23(){ $this->_retvalue = $this->yystack[$this->yyidx + 0]->minor; }
1827 : #line 1832 "internal.templateparser.php"
1828 : #line 182 "internal.templateparser.y"
1829 14 : function yy_r24(){ $this->_retvalue = $this->compiler->compileTag($this->yystack[$this->yyidx + -6]->minor,array('from'=>$this->yystack[$this->yyidx + -1]->minor,'item'=>$this->yystack[$this->yyidx + -3]->minor)); }
1830 : #line 1835 "internal.templateparser.php"
1831 : #line 189 "internal.templateparser.y"
1832 57 : function yy_r26(){ $this->_retvalue = array_merge($this->yystack[$this->yyidx + -1]->minor,$this->yystack[$this->yyidx + 0]->minor); }
1833 : #line 1838 "internal.templateparser.php"
1834 : #line 193 "internal.templateparser.y"
1835 220 : function yy_r28(){ $this->_retvalue = array(); }
1836 : #line 1841 "internal.templateparser.php"
1837 : #line 197 "internal.templateparser.y"
1838 84 : function yy_r29(){ $this->_retvalue = array($this->yystack[$this->yyidx + -2]->minor=>$this->yystack[$this->yyidx + 0]->minor); }
1839 : #line 1844 "internal.templateparser.php"
1840 : #line 202 "internal.templateparser.y"
1841 7 : function yy_r30(){ $this->_retvalue = array($this->yystack[$this->yyidx + 0]->minor); }
1842 : #line 1847 "internal.templateparser.php"
1843 : #line 203 "internal.templateparser.y"
1844 1 : function yy_r31(){ $this->yystack[$this->yyidx + -2]->minor[]=$this->yystack[$this->yyidx + 0]->minor; $this->_retvalue = $this->yystack[$this->yyidx + -2]->minor; }
1845 : #line 1850 "internal.templateparser.php"
1846 : #line 205 "internal.templateparser.y"
1847 40 : function yy_r32(){ $this->_retvalue = array('var' => $this->yystack[$this->yyidx + -2]->minor, 'value'=>$this->yystack[$this->yyidx + 0]->minor); }
1848 : #line 1853 "internal.templateparser.php"
1849 : #line 212 "internal.templateparser.y"
1850 60 : function yy_r33(){ $this->_retvalue = '\''.$this->yystack[$this->yyidx + 0]->minor.'\''; }
1851 : #line 1856 "internal.templateparser.php"
1852 : #line 216 "internal.templateparser.y"
1853 : function yy_r35(){
1854 12 : if ($this->smarty->plugin_handler->loadSmartyPlugin($this->yystack[$this->yyidx + -1]->minor[0],'modifier')) {
1855 4 : $this->_retvalue = "\$_smarty_tpl->smarty->plugin_handler->".$this->yystack[$this->yyidx + -1]->minor[0] . "(array(". $this->yystack[$this->yyidx + -2]->minor . $this->yystack[$this->yyidx + 0]->minor ."),'modifier')";
1856 4 : } else {
1857 9 : if ($this->yystack[$this->yyidx + -1]->minor[0] == 'isset' || $this->yystack[$this->yyidx + -1]->minor[0] == 'empty' || is_callable($this->yystack[$this->yyidx + -1]->minor[0])) {
1858 8 : if (!$this->template->security || $this->smarty->security_handler->isTrustedModifier($this->yystack[$this->yyidx + -1]->minor[0], $this->compiler)) {
1859 7 : $this->_retvalue = $this->yystack[$this->yyidx + -1]->minor[0] . "(". $this->yystack[$this->yyidx + -2]->minor . $this->yystack[$this->yyidx + 0]->minor .")";
1860 7 : }
1861 7 : } else {
1862 1 : $this->compiler->trigger_template_error ("unknown modifier \"" . $this->yystack[$this->yyidx + -1]->minor[0] . "\"");
1863 : }
1864 : }
1865 10 : }
1866 : #line 1871 "internal.templateparser.php"
1867 : #line 234 "internal.templateparser.y"
1868 1 : function yy_r38(){ $this->_retvalue = $this->yystack[$this->yyidx + -1]->minor.$this->yystack[$this->yyidx + 0]->minor; }
1869 : #line 1874 "internal.templateparser.php"
1870 : #line 236 "internal.templateparser.y"
1871 6 : function yy_r39(){ $this->_retvalue = $this->yystack[$this->yyidx + -2]->minor . $this->yystack[$this->yyidx + -1]->minor . $this->yystack[$this->yyidx + 0]->minor; }
1872 : #line 1877 "internal.templateparser.php"
1873 : #line 238 "internal.templateparser.y"
1874 0 : function yy_r40(){ $this->_retvalue = '('. $this->yystack[$this->yyidx + -2]->minor . ').(' . $this->yystack[$this->yyidx + 0]->minor. ')'; }
1875 : #line 1880 "internal.templateparser.php"
1876 : #line 252 "internal.templateparser.y"
1877 12 : function yy_r44(){$this->_retvalue = '$_smarty_tpl->getConfigVariable(\''. $this->yystack[$this->yyidx + -1]->minor .'\')'; }
1878 : #line 1883 "internal.templateparser.php"
1879 : #line 263 "internal.templateparser.y"
1880 1 : function yy_r49(){ $this->_retvalue = "(". $this->yystack[$this->yyidx + -1]->minor .")"; }
1881 : #line 1886 "internal.templateparser.php"
1882 : #line 266 "internal.templateparser.y"
1883 50 : function yy_r50(){ $this->_retvalue = "'".$this->yystack[$this->yyidx + -1]->minor."'"; }
1884 : #line 1889 "internal.templateparser.php"
1885 : #line 267 "internal.templateparser.y"
1886 2 : function yy_r51(){ $this->_retvalue = "''"; }
1887 : #line 1892 "internal.templateparser.php"
1888 : #line 269 "internal.templateparser.y"
1889 39 : function yy_r52(){ $this->_retvalue = "'".str_replace('\"','"',$this->yystack[$this->yyidx + -1]->minor)."'"; }
1890 : #line 1895 "internal.templateparser.php"
1891 : #line 275 "internal.templateparser.y"
1892 1 : function yy_r54(){ $this->_retvalue = $this->yystack[$this->yyidx + -2]->minor.'::'.$this->yystack[$this->yyidx + 0]->minor; }
1893 : #line 1898 "internal.templateparser.php"
1894 : #line 276 "internal.templateparser.y"
1895 2 : function yy_r55(){ $this->prefix_number++; $this->prefix_code[] = '<?php $_tmp'.$this->prefix_number.'=$_smarty_tpl->getVariable(\''. $this->yystack[$this->yyidx + -3]->minor .'\')->value;?>'; $this->_retvalue = $this->yystack[$this->yyidx + -6]->minor.'::$_tmp'.$this->prefix_number.'('. $this->yystack[$this->yyidx + -1]->minor .')'; }
1896 : #line 1901 "internal.templateparser.php"
1897 : #line 278 "internal.templateparser.y"
1898 0 : function yy_r56(){ $this->_retvalue = $this->yystack[$this->yyidx + -3]->minor.'::'.$this->yystack[$this->yyidx + -1]->minor.$this->yystack[$this->yyidx + 0]->minor; }
1899 : #line 1904 "internal.templateparser.php"
1900 : #line 279 "internal.templateparser.y"
1901 0 : function yy_r57(){ $this->prefix_number++; $this->prefix_code[] = '<?php $_tmp'.$this->prefix_number.'=$_smarty_tpl->getVariable(\''. $this->yystack[$this->yyidx + -4]->minor .'\')->value;?>'; $this->_retvalue = $this->yystack[$this->yyidx + -7]->minor.'::$_tmp'.$this->prefix_number.'('. $this->yystack[$this->yyidx + -2]->minor .')'.$this->yystack[$this->yyidx + 0]->minor; }
1902 : #line 1907 "internal.templateparser.php"
1903 : #line 281 "internal.templateparser.y"
1904 1 : function yy_r58(){ $this->_retvalue = $this->yystack[$this->yyidx + -2]->minor.'::'.$this->yystack[$this->yyidx + 0]->minor; }
1905 : #line 1910 "internal.templateparser.php"
1906 : #line 283 "internal.templateparser.y"
1907 1 : function yy_r59(){ $this->_retvalue = $this->yystack[$this->yyidx + -4]->minor.'::$'.$this->yystack[$this->yyidx + -1]->minor.$this->yystack[$this->yyidx + 0]->minor; }
1908 : #line 1913 "internal.templateparser.php"
1909 : #line 285 "internal.templateparser.y"
1910 0 : function yy_r60(){ $this->_retvalue = $this->yystack[$this->yyidx + -5]->minor.'::$'.$this->yystack[$this->yyidx + -2]->minor.$this->yystack[$this->yyidx + -1]->minor.$this->yystack[$this->yyidx + 0]->minor; }
1911 : #line 1916 "internal.templateparser.php"
1912 : #line 292 "internal.templateparser.y"
1913 126 : function yy_r61(){ if ($this->yystack[$this->yyidx + -1]->minor == '\'smarty\'') { $this->_retvalue = $this->compiler->compileTag(trim($this->yystack[$this->yyidx + -1]->minor,"'"),$this->yystack[$this->yyidx + 0]->minor);} else {
1914 126 : $this->_retvalue = '$_smarty_tpl->getVariable('. $this->yystack[$this->yyidx + -1]->minor .')->value'.$this->yystack[$this->yyidx + 0]->minor; $this->nocache=$this->template->getVariable(trim($this->yystack[$this->yyidx + -1]->minor,"'"))->nocache;} }
1915 : #line 1920 "internal.templateparser.php"
1916 : #line 295 "internal.templateparser.y"
1917 7 : function yy_r62(){ $this->_retvalue = '$_smarty_tpl->getVariable('. $this->yystack[$this->yyidx + -2]->minor .')->'.$this->yystack[$this->yyidx + 0]->minor; $this->nocache=$this->template->getVariable(trim($this->yystack[$this->yyidx + -2]->minor,"'"))->nocache; }
1918 : #line 1923 "internal.templateparser.php"
1919 : #line 307 "internal.templateparser.y"
1920 133 : function yy_r65(){return; }
1921 : #line 1926 "internal.templateparser.php"
1922 : #line 311 "internal.templateparser.y"
1923 11 : function yy_r66(){ $this->_retvalue = "['". $this->yystack[$this->yyidx + 0]->minor ."']"; }
1924 : #line 1929 "internal.templateparser.php"
1925 : #line 312 "internal.templateparser.y"
1926 1 : function yy_r67(){ $this->_retvalue = "[". $this->yystack[$this->yyidx + 0]->minor ."]"; }
1927 : #line 1932 "internal.templateparser.php"
1928 : #line 314 "internal.templateparser.y"
1929 5 : function yy_r68(){ $this->_retvalue = '['.$this->compiler->compileTag('smarty','[\'section\'][\''.$this->yystack[$this->yyidx + -1]->minor.'\'][\'index\']').']'; }
1930 : #line 1935 "internal.templateparser.php"
1931 : #line 316 "internal.templateparser.y"
1932 12 : function yy_r69(){ $this->_retvalue = "[". $this->yystack[$this->yyidx + -1]->minor ."]"; }
1933 : #line 1938 "internal.templateparser.php"
1934 : #line 324 "internal.templateparser.y"
1935 3 : function yy_r71(){$this->_retvalue = $this->yystack[$this->yyidx + -1]->minor.'.'.$this->yystack[$this->yyidx + 0]->minor; }
1936 : #line 1941 "internal.templateparser.php"
1937 : #line 326 "internal.templateparser.y"
1938 127 : function yy_r72(){$this->_retvalue = '\''.$this->yystack[$this->yyidx + 0]->minor.'\''; }
1939 : #line 1944 "internal.templateparser.php"
1940 : #line 328 "internal.templateparser.y"
1941 8 : function yy_r73(){$this->_retvalue = '('.$this->yystack[$this->yyidx + -1]->minor.')'; }
1942 : #line 1947 "internal.templateparser.php"
1943 : #line 333 "internal.templateparser.y"
1944 0 : function yy_r74(){ $this->_retvalue = '$_smarty_tpl->getVariable('. $this->yystack[$this->yyidx + -2]->minor .')->value'.$this->yystack[$this->yyidx + -1]->minor.$this->yystack[$this->yyidx + 0]->minor; $this->nocache=$this->template->getVariable(trim($this->yystack[$this->yyidx + -2]->minor,"'"))->nocache; }
1945 : #line 1950 "internal.templateparser.php"
1946 : #line 335 "internal.templateparser.y"
1947 0 : function yy_r75(){$this->_retvalue = $this->yystack[$this->yyidx + 0]->minor; }
1948 : #line 1953 "internal.templateparser.php"
1949 : #line 337 "internal.templateparser.y"
1950 0 : function yy_r76(){$this->_retvalue = $this->yystack[$this->yyidx + -1]->minor.$this->yystack[$this->yyidx + 0]->minor; }
1951 : #line 1956 "internal.templateparser.php"
1952 : #line 339 "internal.templateparser.y"
1953 0 : function yy_r77(){ $this->_retvalue = '->'.$this->yystack[$this->yyidx + -1]->minor.$this->yystack[$this->yyidx + 0]->minor; }
1954 : #line 1959 "internal.templateparser.php"
1955 : #line 342 "internal.templateparser.y"
1956 0 : function yy_r78(){ $this->_retvalue = '->'.$this->yystack[$this->yyidx + 0]->minor; }
1957 : #line 1962 "internal.templateparser.php"
1958 : #line 348 "internal.templateparser.y"
1959 10 : function yy_r79(){if (!$this->template->security || $this->smarty->security_handler->isTrustedPhpFunction($this->yystack[$this->yyidx + -3]->minor, $this->compiler)) {
1960 9 : if ($this->yystack[$this->yyidx + -3]->minor == 'isset' || $this->yystack[$this->yyidx + -3]->minor == 'empty' || is_callable($this->yystack[$this->yyidx + -3]->minor)) {
1961 8 : $this->_retvalue = $this->yystack[$this->yyidx + -3]->minor . "(". $this->yystack[$this->yyidx + -1]->minor .")";
1962 8 : } else {
1963 1 : $this->compiler->trigger_template_error ("unknown function \"" . $this->yystack[$this->yyidx + -3]->minor . "\"");
1964 : }
1965 8 : } }
1966 : #line 1971 "internal.templateparser.php"
1967 : #line 359 "internal.templateparser.y"
1968 1 : function yy_r80(){ $this->_retvalue = $this->yystack[$this->yyidx + -3]->minor . "(". $this->yystack[$this->yyidx + -1]->minor .")"; }
1969 : #line 1974 "internal.templateparser.php"
1970 : #line 363 "internal.templateparser.y"
1971 0 : function yy_r81(){ $this->_retvalue = $this->yystack[$this->yyidx + -2]->minor.",".$this->yystack[$this->yyidx + 0]->minor; }
1972 : #line 1977 "internal.templateparser.php"
1973 : #line 367 "internal.templateparser.y"
1974 1 : function yy_r83(){ return; }
1975 : #line 1980 "internal.templateparser.php"
1976 : #line 372 "internal.templateparser.y"
1977 0 : function yy_r84(){ $this->_retvalue = array($this->yystack[$this->yyidx + 0]->minor,true); }
1978 : #line 1983 "internal.templateparser.php"
1979 : #line 373 "internal.templateparser.y"
1980 13 : function yy_r85(){ $this->_retvalue = array($this->yystack[$this->yyidx + 0]->minor,false); }
1981 : #line 1986 "internal.templateparser.php"
1982 : #line 380 "internal.templateparser.y"
1983 5 : function yy_r86(){ $this->_retvalue = $this->yystack[$this->yyidx + -1]->minor.$this->yystack[$this->yyidx + 0]->minor; }
1984 : #line 1989 "internal.templateparser.php"
1985 : #line 384 "internal.templateparser.y"
1986 1 : function yy_r88(){$this->_retvalue = ',\''.$this->yystack[$this->yyidx + 0]->minor.'\''; }
1987 : #line 1992 "internal.templateparser.php"
1988 : #line 385 "internal.templateparser.y"
1989 4 : function yy_r89(){$this->_retvalue = ','.$this->yystack[$this->yyidx + 0]->minor; }
1990 : #line 1995 "internal.templateparser.php"
1991 : #line 392 "internal.templateparser.y"
1992 2 : function yy_r91(){$this->_retvalue = '!'.$this->yystack[$this->yyidx + 0]->minor; }
1993 : #line 1998 "internal.templateparser.php"
1994 : #line 397 "internal.templateparser.y"
1995 22 : function yy_r93(){$this->_retvalue =$this->yystack[$this->yyidx + 0]->minor; }
1996 : #line 2001 "internal.templateparser.php"
1997 : #line 398 "internal.templateparser.y"
1998 53 : function yy_r94(){$this->_retvalue = $this->yystack[$this->yyidx + -2]->minor.$this->yystack[$this->yyidx + -1]->minor.$this->yystack[$this->yyidx + 0]->minor; }
1999 : #line 2004 "internal.templateparser.php"
2000 : #line 400 "internal.templateparser.y"
2001 1 : function yy_r96(){$this->_retvalue = '!('.$this->yystack[$this->yyidx + -2]->minor.' % '.$this->yystack[$this->yyidx + 0]->minor.')'; }
2002 : #line 2007 "internal.templateparser.php"
2003 : #line 401 "internal.templateparser.y"
2004 1 : function yy_r97(){$this->_retvalue = '('.$this->yystack[$this->yyidx + -2]->minor.' % '.$this->yystack[$this->yyidx + 0]->minor.')'; }
2005 : #line 2010 "internal.templateparser.php"
2006 : #line 402 "internal.templateparser.y"
2007 2 : function yy_r98(){$this->_retvalue = '!(1 & '.$this->yystack[$this->yyidx + -1]->minor.')'; }
2008 : #line 2013 "internal.templateparser.php"
2009 : #line 403 "internal.templateparser.y"
2010 2 : function yy_r99(){$this->_retvalue = '(1 & '.$this->yystack[$this->yyidx + -1]->minor.')'; }
2011 : #line 2016 "internal.templateparser.php"
2012 : #line 404 "internal.templateparser.y"
2013 1 : function yy_r100(){$this->_retvalue = '!(1 & '.$this->yystack[$this->yyidx + -2]->minor.' / '.$this->yystack[$this->yyidx + 0]->minor.')'; }
2014 : #line 2019 "internal.templateparser.php"
2015 : #line 405 "internal.templateparser.y"
2016 3 : function yy_r101(){$this->_retvalue = '(1 & '.$this->yystack[$this->yyidx + -2]->minor.' / '.$this->yystack[$this->yyidx + 0]->minor.')'; }
2017 : #line 2022 "internal.templateparser.php"
2018 : #line 411 "internal.templateparser.y"
2019 7 : function yy_r106(){$this->_retvalue = '=='; }
2020 : #line 2025 "internal.templateparser.php"
2021 : #line 412 "internal.templateparser.y"
2022 4 : function yy_r107(){$this->_retvalue = '!='; }
2023 : #line 2028 "internal.templateparser.php"
2024 : #line 413 "internal.templateparser.y"
2025 13 : function yy_r108(){$this->_retvalue = '>'; }
2026 : #line 2031 "internal.templateparser.php"
2027 : #line 414 "internal.templateparser.y"
2028 22 : function yy_r109(){$this->_retvalue = '<'; }
2029 : #line 2034 "internal.templateparser.php"
2030 : #line 415 "internal.templateparser.y"
2031 7 : function yy_r110(){$this->_retvalue = '>='; }
2032 : #line 2037 "internal.templateparser.php"
2033 : #line 416 "internal.templateparser.y"
2034 4 : function yy_r111(){$this->_retvalue = '<='; }
2035 : #line 2040 "internal.templateparser.php"
2036 : #line 417 "internal.templateparser.y"
2037 3 : function yy_r112(){$this->_retvalue = '==='; }
2038 : #line 2043 "internal.templateparser.php"
2039 : #line 418 "internal.templateparser.y"
2040 0 : function yy_r113(){$this->_retvalue = '!=='; }
2041 : #line 2046 "internal.templateparser.php"
2042 : #line 420 "internal.templateparser.y"
2043 5 : function yy_r114(){$this->_retvalue = '&&'; }
2044 : #line 2049 "internal.templateparser.php"
2045 : #line 421 "internal.templateparser.y"
2046 5 : function yy_r115(){$this->_retvalue = '||'; }
2047 : #line 2052 "internal.templateparser.php"
2048 : #line 426 "internal.templateparser.y"
2049 32 : function yy_r116(){ $this->_retvalue = 'array('.$this->yystack[$this->yyidx + -1]->minor.')'; }
2050 : #line 2055 "internal.templateparser.php"
2051 : #line 428 "internal.templateparser.y"
2052 32 : function yy_r118(){ $this->_retvalue = $this->yystack[$this->yyidx + -2]->minor.','.$this->yystack[$this->yyidx + 0]->minor; }
2053 : #line 2058 "internal.templateparser.php"
2054 : #line 429 "internal.templateparser.y"
2055 0 : function yy_r119(){ return; }
2056 : #line 2061 "internal.templateparser.php"
2057 : #line 431 "internal.templateparser.y"
2058 3 : function yy_r121(){ $this->_retvalue = $this->yystack[$this->yyidx + -2]->minor.'=>'.$this->yystack[$this->yyidx + 0]->minor; }
2059 : #line 2064 "internal.templateparser.php"
2060 : #line 432 "internal.templateparser.y"
2061 1 : function yy_r122(){ $this->_retvalue = '\''.$this->yystack[$this->yyidx + -2]->minor.'\'=>'.$this->yystack[$this->yyidx + 0]->minor; }
2062 : #line 2067 "internal.templateparser.php"
2063 : #line 439 "internal.templateparser.y"
2064 1 : function yy_r125(){$this->_retvalue = "'.".$this->yystack[$this->yyidx + 0]->minor.".'"; }
2065 : #line 2070 "internal.templateparser.php"
2066 : #line 440 "internal.templateparser.y"
2067 1 : function yy_r126(){$this->_retvalue = "'.".$this->yystack[$this->yyidx + -1]->minor.".'"; }
2068 : #line 2073 "internal.templateparser.php"
2069 : #line 441 "internal.templateparser.y"
2070 2 : function yy_r127(){$this->_retvalue = "'.(".$this->yystack[$this->yyidx + -1]->minor.").'"; }
2071 : #line 2076 "internal.templateparser.php"
2072 : #line 442 "internal.templateparser.y"
2073 39 : function yy_r128(){$this->_retvalue = addcslashes($this->yystack[$this->yyidx + 0]->minor,"'"); }
2074 : #line 2079 "internal.templateparser.php"
2075 :
2076 : /**
2077 : * placeholder for the left hand side in a reduce operation.
2078 : *
2079 : * For a parser with a rule like this:
2080 : * <pre>
2081 : * rule(A) ::= B. { A = 1; }
2082 : * </pre>
2083 : *
2084 : * The parser will translate to something like:
2085 : *
2086 : * <code>
2087 : * function yy_r0(){$this->_retvalue = 1;}
2088 : * </code>
2089 : */
2090 : private $_retvalue;
2091 :
2092 : /**
2093 : * Perform a reduce action and the shift that must immediately
2094 : * follow the reduce.
2095 : *
2096 : * For a rule such as:
2097 : *
2098 : * <pre>
2099 : * A ::= B blah C. { dosomething(); }
2100 : * </pre>
2101 : *
2102 : * This function will first call the action, if any, ("dosomething();" in our
2103 : * example), and then it will pop three states from the stack,
2104 : * one for each entry on the right-hand side of the expression
2105 : * (B, blah, and C in our example rule), and then push the result of the action
2106 : * back on to the stack with the resulting state reduced to (as described in the .out
2107 : * file)
2108 : * @param int Number of the rule by which to reduce
2109 : */
2110 : function yy_reduce($yyruleno)
2111 : {
2112 : //int $yygoto; /* The next state */
2113 : //int $yyact; /* The next action */
2114 : //mixed $yygotominor; /* The LHS of the rule reduced */
2115 : //TP_yyStackEntry $yymsp; /* The top of the parser's stack */
2116 : //int $yysize; /* Amount to pop the stack */
2117 277 : $yymsp = $this->yystack[$this->yyidx];
2118 277 : if (self::$yyTraceFILE && $yyruleno >= 0
2119 277 : && $yyruleno < count(self::$yyRuleName)) {
2120 0 : fprintf(self::$yyTraceFILE, "%sReduce (%d) [%s].\n",
2121 0 : self::$yyTracePrompt, $yyruleno,
2122 0 : self::$yyRuleName[$yyruleno]);
2123 0 : }
2124 :
2125 277 : $this->_retvalue = $yy_lefthand_side = null;
2126 277 : if (array_key_exists($yyruleno, self::$yyReduceMap)) {
2127 : // call the action
2128 277 : $this->_retvalue = null;
2129 277 : $this->{'yy_r' . self::$yyReduceMap[$yyruleno]}();
2130 277 : $yy_lefthand_side = $this->_retvalue;
2131 277 : }
2132 277 : $yygoto = self::$yyRuleInfo[$yyruleno]['lhs'];
2133 277 : $yysize = self::$yyRuleInfo[$yyruleno]['rhs'];
2134 277 : $this->yyidx -= $yysize;
2135 277 : for($i = $yysize; $i; $i--) {
2136 : // pop all of the right-hand side parameters
2137 275 : array_pop($this->yystack);
2138 275 : }
2139 277 : $yyact = $this->yy_find_reduce_action($this->yystack[$this->yyidx]->stateno, $yygoto);
2140 277 : if ($yyact < self::YYNSTATE) {
2141 : /* If we are not debugging and the reduce action popped at least
2142 : ** one element off the stack, then we can push the new element back
2143 : ** onto the stack here, and skip the stack overflow test in yy_shift().
2144 : ** That gives a significant speed improvement. */
2145 277 : if (!self::$yyTraceFILE && $yysize) {
2146 275 : $this->yyidx++;
2147 275 : $x = new TP_yyStackEntry;
2148 275 : $x->stateno = $yyact;
2149 275 : $x->major = $yygoto;
2150 275 : $x->minor = $yy_lefthand_side;
2151 275 : $this->yystack[$this->yyidx] = $x;
2152 275 : } else {
2153 226 : $this->yy_shift($yyact, $yygoto, $yy_lefthand_side);
2154 : }
2155 277 : } elseif ($yyact == self::YYNSTATE + self::YYNRULE + 1) {
2156 268 : $this->yy_accept();
2157 268 : }
2158 277 : }
2159 :
2160 : /**
2161 : * The following code executes when the parse fails
2162 : *
2163 : * Code from %parse_fail is inserted here
2164 : */
2165 : function yy_parse_failed()
2166 : {
2167 0 : if (self::$yyTraceFILE) {
2168 0 : fprintf(self::$yyTraceFILE, "%sFail!\n", self::$yyTracePrompt);
2169 0 : }
2170 0 : while ($this->yyidx >= 0) {
2171 0 : $this->yy_pop_parser_stack();
2172 0 : }
2173 : /* Here code is inserted which will be executed whenever the
2174 : ** parser fails */
2175 0 : }
2176 :
2177 : /**
2178 : * The following code executes when a syntax error first occurs.
2179 : *
2180 : * %syntax_error code is inserted here
2181 : * @param int The major type of the error token
2182 : * @param mixed The minor type of the error token
2183 : */
2184 : function yy_syntax_error($yymajor, $TOKEN)
2185 : {
2186 : #line 55 "internal.templateparser.y"
2187 :
2188 1 : $this->internalError = true;
2189 1 : $this->yymajor = $yymajor;
2190 1 : $this->compiler->trigger_template_error();
2191 : #line 2197 "internal.templateparser.php"
2192 0 : }
2193 :
2194 : /**
2195 : * The following is executed when the parser accepts
2196 : *
2197 : * %parse_accept code is inserted here
2198 : */
2199 : function yy_accept()
2200 : {
2201 268 : if (self::$yyTraceFILE) {
2202 0 : fprintf(self::$yyTraceFILE, "%sAccept!\n", self::$yyTracePrompt);
2203 0 : }
2204 268 : while ($this->yyidx >= 0) {
2205 268 : $stack = $this->yy_pop_parser_stack();
2206 268 : }
2207 : /* Here code is inserted which will be executed whenever the
2208 : ** parser accepts */
2209 : #line 47 "internal.templateparser.y"
2210 :
2211 268 : $this->successful = !$this->internalError;
2212 268 : $this->internalError = false;
2213 268 : $this->retvalue = $this->_retvalue;
2214 : //echo $this->retvalue."\n\n";
2215 : #line 2222 "internal.templateparser.php"
2216 268 : }
2217 :
2218 : /**
2219 : * The main parser program.
2220 : *
2221 : * The first argument is the major token number. The second is
2222 : * the token value string as scanned from the input.
2223 : *
2224 : * @param int the token number
2225 : * @param mixed the token value
2226 : * @param mixed any extra arguments that should be passed to handlers
2227 : */
2228 : function doParse($yymajor, $yytokenvalue)
2229 : {
2230 : // $yyact; /* The parser action. */
2231 : // $yyendofinput; /* True if we are at the end of input */
2232 278 : $yyerrorhit = 0; /* True if yymajor has invoked an error */
2233 :
2234 : /* (re)initialize the parser, if necessary */
2235 278 : if ($this->yyidx === null || $this->yyidx < 0) {
2236 : /* if ($yymajor == 0) return; // not sure why this was here... */
2237 278 : $this->yyidx = 0;
2238 278 : $this->yyerrcnt = -1;
2239 278 : $x = new TP_yyStackEntry;
2240 278 : $x->stateno = 0;
2241 278 : $x->major = 0;
2242 278 : $this->yystack = array();
2243 278 : array_push($this->yystack, $x);
2244 278 : }
2245 278 : $yyendofinput = ($yymajor==0);
2246 :
2247 278 : if (self::$yyTraceFILE) {
2248 0 : fprintf(self::$yyTraceFILE, "%sInput %s\n",
2249 0 : self::$yyTracePrompt, $this->yyTokenName[$yymajor]);
2250 0 : }
2251 :
2252 : do {
2253 278 : $yyact = $this->yy_find_shift_action($yymajor);
2254 278 : if ($yymajor < self::YYERRORSYMBOL &&
2255 278 : !$this->yy_is_expected_token($yymajor)) {
2256 : // force a syntax error
2257 0 : $yyact = self::YY_ERROR_ACTION;
2258 0 : }
2259 278 : if ($yyact < self::YYNSTATE) {
2260 278 : $this->yy_shift($yyact, $yymajor, $yytokenvalue);
2261 278 : $this->yyerrcnt--;
2262 278 : if ($yyendofinput && $this->yyidx >= 0) {
2263 0 : $yymajor = 0;
2264 0 : } else {
2265 278 : $yymajor = self::YYNOCODE;
2266 : }
2267 278 : } elseif ($yyact < self::YYNSTATE + self::YYNRULE) {
2268 277 : $this->yy_reduce($yyact - self::YYNSTATE);
2269 278 : } elseif ($yyact == self::YY_ERROR_ACTION) {
2270 1 : if (self::$yyTraceFILE) {
2271 0 : fprintf(self::$yyTraceFILE, "%sSyntax Error!\n",
2272 0 : self::$yyTracePrompt);
2273 0 : }
2274 1 : if (self::YYERRORSYMBOL) {
2275 : /* A syntax error has occurred.
2276 : ** The response to an error depends upon whether or not the
2277 : ** grammar defines an error token "ERROR".
2278 : **
2279 : ** This is what we do if the grammar does define ERROR:
2280 : **
2281 : ** * Call the %syntax_error function.
2282 : **
2283 : ** * Begin popping the stack until we enter a state where
2284 : ** it is legal to shift the error symbol, then shift
2285 : ** the error symbol.
2286 : **
2287 : ** * Set the error count to three.
2288 : **
2289 : ** * Begin accepting and shifting new tokens. No new error
2290 : ** processing will occur until three tokens have been
2291 : ** shifted successfully.
2292 : **
2293 : */
2294 1 : if ($this->yyerrcnt < 0) {
2295 1 : $this->yy_syntax_error($yymajor, $yytokenvalue);
2296 0 : }
2297 0 : $yymx = $this->yystack[$this->yyidx]->major;
2298 0 : if ($yymx == self::YYERRORSYMBOL || $yyerrorhit ){
2299 0 : if (self::$yyTraceFILE) {
2300 0 : fprintf(self::$yyTraceFILE, "%sDiscard input token %s\n",
2301 0 : self::$yyTracePrompt, $this->yyTokenName[$yymajor]);
2302 0 : }
2303 0 : $this->yy_destructor($yymajor, $yytokenvalue);
2304 0 : $yymajor = self::YYNOCODE;
2305 0 : } else {
2306 0 : while ($this->yyidx >= 0 &&
2307 0 : $yymx != self::YYERRORSYMBOL &&
2308 0 : ($yyact = $this->yy_find_shift_action(self::YYERRORSYMBOL)) >= self::YYNSTATE
2309 0 : ){
2310 0 : $this->yy_pop_parser_stack();
2311 0 : }
2312 0 : if ($this->yyidx < 0 || $yymajor==0) {
2313 0 : $this->yy_destructor($yymajor, $yytokenvalue);
2314 0 : $this->yy_parse_failed();
2315 0 : $yymajor = self::YYNOCODE;
2316 0 : } elseif ($yymx != self::YYERRORSYMBOL) {
2317 0 : $u2 = 0;
2318 0 : $this->yy_shift($yyact, self::YYERRORSYMBOL, $u2);
2319 0 : }
2320 : }
2321 0 : $this->yyerrcnt = 3;
2322 0 : $yyerrorhit = 1;
2323 0 : } else {
2324 : /* YYERRORSYMBOL is not defined */
2325 : /* This is what we do if the grammar does not define ERROR:
2326 : **
2327 : ** * Report an error message, and throw away the input token.
2328 : **
2329 : ** * If the input token is $, then fail the parse.
2330 : **
2331 : ** As before, subsequent error messages are suppressed until
2332 : ** three input tokens have been successfully shifted.
2333 : */
2334 0 : if ($this->yyerrcnt <= 0) {
2335 0 : $this->yy_syntax_error($yymajor, $yytokenvalue);
2336 0 : }
2337 0 : $this->yyerrcnt = 3;
2338 0 : $this->yy_destructor($yymajor, $yytokenvalue);
2339 0 : if ($yyendofinput) {
2340 0 : $this->yy_parse_failed();
2341 0 : }
2342 0 : $yymajor = self::YYNOCODE;
2343 : }
2344 0 : } else {
2345 0 : $this->yy_accept();
2346 0 : $yymajor = self::YYNOCODE;
2347 : }
2348 278 : } while ($yymajor != self::YYNOCODE && $this->yyidx >= 0);
2349 278 : }
2350 : }
|